Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move physics enter/exit back to reactors #10193

Merged
merged 6 commits into from
May 22, 2024

Conversation

HexaField
Copy link
Member

@HexaField HexaField commented May 20, 2024

Summary

As part of the physics API refactor, the physics ECS component create/destroy functionality were moved from component reactors to enter/exit queries. This was due to insuficiencies in the gaurantees of scene loading.

This concern has since been addressed, and with the recent upgrades to hookstate that allow for a changing source to be hooked, we can simplify the component reactors. This includes changes to useAncestorWithComponent and useChildWithComponent that now react to changes in passed arguments.

Subtasks Checklist

Breaking Changes

References

closes #insert number here

QA Steps

@speigg
Copy link
Member

speigg commented May 20, 2024

Seems to be a memory leak introduced here that is causing the heap to run out of memory.

@HexaField
Copy link
Member Author

Seems to be a memory leak introduced here that is causing the heap to run out of memory.

Fixed. It was the change to useQuery.

@HexaField HexaField merged commit c9db405 into dev May 22, 2024
13 checks passed
@HexaField HexaField deleted the revert-to-physics-reactors-with-new-hookstate-api branch May 22, 2024 03:26
MbfloydIR added a commit that referenced this pull request May 24, 2024
* dev: (63 commits)
  hotfix vrm0 data not being where we expect it (#10236)
  Update tween.js version (#10241)
  Added ProjectPermissionDatabaseType
  physics bug fix (#10221)
  updated the background to use the color with when in wireframe render mode (#10231)
  vrm expressionmanager was being thrown away it is actually needed for viseme support to work (#10230)
  IR-1887-Asset-Preview-breaking-if-you-click-gltf-that-is-in-the-scene (#10208)
  query function fix (#10229)
  IR-2102 Material/Plugin Parameters (#10180)
  Fixed webcam light not turning off when camera paused. (#10224)
  Made client's server.js not bound to a specific host (#10223)
  Update FeathersHooks.tsx (#10228)
  Updated app name
  feat(setup): update logo and components props (#10204)
  Changes for feature flag schema to be string enum (#10225)
  Cleaned location hooks (#10216)
  Ir 1652 interactable input refactor (#10219)
  IR-2018 Refactor the Select component to disable search functionality for the dropdown only (#10206)
  refactor: Update Primus initialization to include pathname in server URL (#10205)
  Move physics enter/exit back to reactors (#10193)
  ...

# Conflicts:
#	packages/editor/src/components/element/ElementList.tsx
#	packages/editor/src/components/properties/PostProcessingSettingsEditor.tsx
#	packages/engine/src/scene/SceneModule.ts
#	packages/spatial/src/renderer/components/PostProcessingComponent.tsx
#	packages/spatial/src/renderer/functions/configureEffectComposer.ts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants