@relu-interactives/spatial-ecs 0.2.12 → 0.2.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (220) hide show
  1. package/dist/{System-CHCucemW.d.cts → System-BeuJ1xt5.d.cts} +291 -2
  2. package/dist/{System-CHCucemW.d.ts → System-BeuJ1xt5.d.ts} +291 -2
  3. package/dist/{Video-B9ZKmBIT.d.ts → Video-Cym2C52L.d.ts} +2 -241
  4. package/dist/{Video-ACTSfWjH.d.cts → Video-D4B-z74P.d.cts} +2 -241
  5. package/dist/{chunk-PH43YHUT.js → chunk-27RBPOVO.js} +3 -3
  6. package/dist/{chunk-PH43YHUT.js.map → chunk-27RBPOVO.js.map} +1 -1
  7. package/dist/{chunk-ZCEMOTH4.js → chunk-7QBONTBW.js} +4 -4
  8. package/dist/{chunk-ZCEMOTH4.js.map → chunk-7QBONTBW.js.map} +1 -1
  9. package/dist/{chunk-XPCVEXMY.js → chunk-FTIQQK62.js} +2 -2
  10. package/dist/chunk-FTIQQK62.js.map +1 -0
  11. package/dist/{chunk-ON4E5E5O.js → chunk-KDZ6VBRO.js} +4 -4
  12. package/dist/{chunk-ON4E5E5O.js.map → chunk-KDZ6VBRO.js.map} +1 -1
  13. package/dist/components/index.cjs.map +1 -1
  14. package/dist/components/index.d.cts +2 -2
  15. package/dist/components/index.d.ts +2 -2
  16. package/dist/components/index.js +1 -1
  17. package/dist/docs/api/Behaviour/classes/Behaviour.md +29 -29
  18. package/dist/docs/api/Component/classes/Component.md +1 -1
  19. package/dist/docs/api/components/classes/AnimationComponent.md +26 -26
  20. package/dist/docs/api/components/classes/AudioComponent.md +19 -19
  21. package/dist/docs/api/components/classes/CameraComponent.md +14 -14
  22. package/dist/docs/api/components/classes/EntityType.md +3 -3
  23. package/dist/docs/api/components/classes/Environment.md +7 -3
  24. package/dist/docs/api/components/classes/ImageComponent.md +7 -7
  25. package/dist/docs/api/components/classes/ImageTarget.md +7 -7
  26. package/dist/docs/api/components/classes/ImageTargetAnchor.md +4 -4
  27. package/dist/docs/api/components/classes/InstanceSlotComponent.md +4 -4
  28. package/dist/docs/api/components/classes/InstancedMeshComponent.md +10 -10
  29. package/dist/docs/api/components/classes/LightComponent.md +6 -6
  30. package/dist/docs/api/components/classes/MaterialComponent.md +11 -11
  31. package/dist/docs/api/components/classes/MeshComponent.md +3 -3
  32. package/dist/docs/api/components/classes/MeshGeometryComponent.md +9 -9
  33. package/dist/docs/api/components/classes/ModelComponent.md +4 -4
  34. package/dist/docs/api/components/classes/Name.md +3 -3
  35. package/dist/docs/api/components/classes/Object3DRef.md +4 -4
  36. package/dist/docs/api/components/classes/ParentId.md +3 -3
  37. package/dist/docs/api/components/classes/PhysicsComponent.md +6 -6
  38. package/dist/docs/api/components/classes/Postprocessing.md +7 -3
  39. package/dist/docs/api/components/classes/ScriptComponent.md +5 -5
  40. package/dist/docs/api/components/classes/Selectable.md +3 -3
  41. package/dist/docs/api/components/classes/SelectionTransformState.md +5 -5
  42. package/dist/docs/api/components/classes/SpriteComponent.md +7 -7
  43. package/dist/docs/api/components/classes/TransformComponent.md +12 -12
  44. package/dist/docs/api/components/classes/VideoComponent.md +28 -28
  45. package/dist/docs/api/components/functions/normalizePhysicsState.md +1 -1
  46. package/dist/docs/api/components/index.md +1 -1
  47. package/dist/docs/api/components/type-aliases/AnimationComponentOptions.md +9 -9
  48. package/dist/docs/api/components/type-aliases/CameraComponentOptions.md +13 -13
  49. package/dist/docs/api/components/type-aliases/CameraProjection.md +1 -1
  50. package/dist/docs/api/components/type-aliases/CameraRuntimeType.md +1 -1
  51. package/dist/docs/api/components/type-aliases/ColliderShape.md +1 -1
  52. package/dist/docs/api/components/type-aliases/ColliderState.md +20 -20
  53. package/dist/docs/api/components/type-aliases/CubeMeshParameters.md +4 -4
  54. package/dist/docs/api/components/type-aliases/EditableMeshObjectKind.md +1 -1
  55. package/dist/docs/api/components/type-aliases/EnvironmentFogState.md +8 -8
  56. package/dist/docs/api/components/type-aliases/EnvironmentFogType.md +1 -1
  57. package/dist/docs/api/components/type-aliases/EnvironmentGradientEffect.md +1 -1
  58. package/dist/docs/api/components/type-aliases/EnvironmentSkyboxState.md +7 -7
  59. package/dist/docs/api/components/type-aliases/EnvironmentSkyboxType.md +1 -1
  60. package/dist/docs/api/components/type-aliases/EnvironmentState.md +5 -5
  61. package/dist/docs/api/components/type-aliases/ImageTargetAnchorOptions.md +3 -3
  62. package/dist/docs/api/components/type-aliases/ImageTargetReference.md +7 -7
  63. package/dist/docs/api/components/type-aliases/InstanceTransform.md +13 -13
  64. package/dist/docs/api/components/type-aliases/InstancedMeshKind.md +1 -1
  65. package/dist/docs/api/components/type-aliases/LightValueState.md +11 -11
  66. package/dist/docs/api/components/type-aliases/MaterialTypeValue.md +1 -1
  67. package/dist/docs/api/components/type-aliases/MaterialValueState.md +28 -28
  68. package/dist/docs/api/components/type-aliases/MeshGeometryParameters.md +1 -1
  69. package/dist/docs/api/components/type-aliases/MeshGeometryParametersByKind.md +7 -7
  70. package/dist/docs/api/components/type-aliases/PhysicsState.md +3 -3
  71. package/dist/docs/api/components/type-aliases/PlaneMeshParameters.md +3 -3
  72. package/dist/docs/api/components/type-aliases/PostprocessingState.md +62 -62
  73. package/dist/docs/api/components/type-aliases/RadiusHeightMeshParameters.md +3 -3
  74. package/dist/docs/api/components/type-aliases/RadiusMeshParameters.md +2 -2
  75. package/dist/docs/api/components/type-aliases/RigidbodyState.md +17 -17
  76. package/dist/docs/api/components/type-aliases/RigidbodyType.md +1 -1
  77. package/dist/docs/api/components/type-aliases/ScriptEntry.md +9 -9
  78. package/dist/docs/api/components/type-aliases/TextureFilteringValue.md +1 -1
  79. package/dist/docs/api/components/type-aliases/TransformData.md +4 -4
  80. package/dist/docs/api/components/type-aliases/TransformModeValue.md +1 -1
  81. package/dist/docs/api/components/type-aliases/TransformSpaceValue.md +1 -1
  82. package/dist/docs/api/components/type-aliases/Vec3.md +4 -4
  83. package/dist/docs/api/components/variables/DEFAULT_COLLIDER_STATE.md +1 -1
  84. package/dist/docs/api/components/variables/DEFAULT_ENVIRONMENT_STATE.md +1 -1
  85. package/dist/docs/api/components/variables/DEFAULT_INSTANCED_MESH_PARAMETERS.md +1 -1
  86. package/dist/docs/api/components/variables/DEFAULT_INSTANCE_TRANSFORM.md +1 -1
  87. package/dist/docs/api/components/variables/DEFAULT_MESH_GEOMETRY_PARAMETERS.md +1 -1
  88. package/dist/docs/api/components/variables/DEFAULT_PHYSICS_STATE.md +1 -1
  89. package/dist/docs/api/components/variables/DEFAULT_POSTPROCESSING_STATE.md +1 -1
  90. package/dist/docs/api/components/variables/DEFAULT_RIGIDBODY_STATE.md +1 -1
  91. package/dist/docs/api/index/classes/AnimationStateMachine.md +16 -16
  92. package/dist/docs/api/index/classes/AnimationStateManager.md +13 -13
  93. package/dist/docs/api/index/classes/AnimationSystem.md +3 -3
  94. package/dist/docs/api/index/classes/AudioSystem.md +4 -4
  95. package/dist/docs/api/index/classes/CameraSyncSystem.md +2 -2
  96. package/dist/docs/api/index/classes/EnvironmentSyncSystem.md +4 -4
  97. package/dist/docs/api/index/classes/InputSystem.md +33 -33
  98. package/dist/docs/api/index/classes/InstancedMeshSystem.md +2 -2
  99. package/dist/docs/api/index/classes/LightSyncSystem.md +2 -2
  100. package/dist/docs/api/index/classes/MaterialSyncSystem.md +3 -3
  101. package/dist/docs/api/index/classes/MeshGeometrySystem.md +2 -2
  102. package/dist/docs/api/index/classes/ObjectManagementSystem.md +14 -14
  103. package/dist/docs/api/index/classes/ObjectVisibilitySystem.md +2 -2
  104. package/dist/docs/api/index/classes/PhysicsSyncSystem.md +4 -4
  105. package/dist/docs/api/index/classes/PostprocessingSyncSystem.md +4 -4
  106. package/dist/docs/api/index/classes/RenderSystem.md +3 -3
  107. package/dist/docs/api/index/classes/ScriptBehaviourSystem.md +4 -4
  108. package/dist/docs/api/index/classes/TransformSyncSystem.md +2 -2
  109. package/dist/docs/api/index/classes/VideoSystem.md +4 -4
  110. package/dist/docs/api/index/classes/World.md +186 -82
  111. package/dist/docs/api/index/functions/createAnimationComponent.md +1 -1
  112. package/dist/docs/api/index/functions/createAudioComponent.md +1 -1
  113. package/dist/docs/api/index/functions/createCameraComponent.md +1 -1
  114. package/dist/docs/api/index/functions/createEntityTypeComponent.md +1 -1
  115. package/dist/docs/api/index/functions/createEnvironmentComponent.md +1 -1
  116. package/dist/docs/api/index/functions/createImageComponent.md +1 -1
  117. package/dist/docs/api/index/functions/createImageTargetAnchorComponent.md +1 -1
  118. package/dist/docs/api/index/functions/createImageTargetComponent.md +1 -1
  119. package/dist/docs/api/index/functions/createInstanceSlotComponent.md +1 -1
  120. package/dist/docs/api/index/functions/createInstancedMeshComponent.md +1 -1
  121. package/dist/docs/api/index/functions/createLightComponent.md +1 -1
  122. package/dist/docs/api/index/functions/createMaterialComponent.md +1 -1
  123. package/dist/docs/api/index/functions/createMeshComponent.md +1 -1
  124. package/dist/docs/api/index/functions/createMeshGeometryComponent.md +1 -1
  125. package/dist/docs/api/index/functions/createModelComponent.md +1 -1
  126. package/dist/docs/api/index/functions/createNameComponent.md +1 -1
  127. package/dist/docs/api/index/functions/createObject3DRefComponent.md +1 -1
  128. package/dist/docs/api/index/functions/createParentIdComponent.md +1 -1
  129. package/dist/docs/api/index/functions/createPhysicsComponent.md +1 -1
  130. package/dist/docs/api/index/functions/createPostprocessingComponent.md +1 -1
  131. package/dist/docs/api/index/functions/createScriptComponent.md +1 -1
  132. package/dist/docs/api/index/functions/createSelectableComponent.md +1 -1
  133. package/dist/docs/api/index/functions/createSelectionTransformStateComponent.md +1 -1
  134. package/dist/docs/api/index/functions/createSpriteComponent.md +1 -1
  135. package/dist/docs/api/index/functions/createTransformComponent.md +1 -1
  136. package/dist/docs/api/index/functions/createVideoComponent.md +1 -1
  137. package/dist/docs/api/index/functions/hydrateWorldFromSnapshot.md +1 -1
  138. package/dist/docs/api/index/functions/hydrateWorldFromSnapshotDetailed.md +1 -1
  139. package/dist/docs/api/index/functions/registerDefaultComponentFactories.md +1 -1
  140. package/dist/docs/api/index/functions/registerDefaultFactories.md +1 -1
  141. package/dist/docs/api/index/interfaces/EcsSystem.md +3 -3
  142. package/dist/docs/api/index/interfaces/StateMachine.md +13 -13
  143. package/dist/docs/api/index/type-aliases/AnimationStateCallbacks.md +4 -4
  144. package/dist/docs/api/index/type-aliases/ComponentFactory.md +1 -1
  145. package/dist/docs/api/index/type-aliases/EcsComponentFactoryKind.md +1 -1
  146. package/dist/docs/api/index/type-aliases/EcsWorldComponentSnapshot.md +3 -3
  147. package/dist/docs/api/index/type-aliases/EcsWorldStateSnapshotLike.md +4 -4
  148. package/dist/docs/api/index/type-aliases/HydrateWorldFromSnapshotResult.md +3 -3
  149. package/dist/docs/api/index/type-aliases/KeyboardKey.md +1 -1
  150. package/dist/docs/api/index/type-aliases/MouseButton.md +1 -1
  151. package/dist/docs/api/index/type-aliases/SelectionContext.md +4 -4
  152. package/dist/docs/api/index/variables/HYDRATABLE_ENTITY_KINDS.md +1 -1
  153. package/dist/docs/api/index/variables/KeyboardKeys.md +89 -89
  154. package/dist/docs/api/types/type-aliases/AssetInput.md +3 -3
  155. package/dist/docs/api/types/type-aliases/CheckboxInput.md +12 -2
  156. package/dist/docs/api/types/type-aliases/ColorInput.md +1 -1
  157. package/dist/docs/api/types/type-aliases/ComponentInput.md +4 -4
  158. package/dist/docs/api/types/type-aliases/ComponentKind.md +1 -1
  159. package/dist/docs/api/types/type-aliases/DropdownInput.md +3 -3
  160. package/dist/docs/api/types/type-aliases/DropdownOption.md +3 -3
  161. package/dist/docs/api/types/type-aliases/EcsEntityEditorKind.md +1 -1
  162. package/dist/docs/api/types/type-aliases/EcsEntityKind.md +1 -1
  163. package/dist/docs/api/types/type-aliases/EntityId.md +1 -1
  164. package/dist/docs/api/types/type-aliases/EntityInput.md +3 -3
  165. package/dist/docs/api/types/type-aliases/FloatInput.md +1 -1
  166. package/dist/docs/api/types/type-aliases/IntersectionResult.md +3 -3
  167. package/dist/docs/api/types/type-aliases/ParentLookup.md +3 -3
  168. package/dist/docs/api/types/type-aliases/SelectionListener.md +1 -1
  169. package/dist/docs/api/types/type-aliases/SliderInput.md +5 -5
  170. package/dist/docs/api/types/type-aliases/TextInput.md +1 -1
  171. package/dist/docs/api/types/type-aliases/ToggleInput.md +1 -1
  172. package/dist/docs/api/types/type-aliases/Vec3.md +1 -1
  173. package/dist/docs/api/types/type-aliases/Vector2Input.md +3 -3
  174. package/dist/docs/api/types/type-aliases/Vector3Input.md +4 -4
  175. package/dist/docs/api/types/type-aliases/WorldEntityView.md +1 -1
  176. package/dist/docs/guide/accessing-components.md +135 -1
  177. package/dist/docs/guide/authoring-a-behaviour.md +1 -1
  178. package/dist/docs/guide/behaviour-data-binding/asset-input.md +54 -0
  179. package/dist/docs/guide/behaviour-data-binding/checkbox-input.md +38 -0
  180. package/dist/docs/guide/behaviour-data-binding/color-input.md +38 -0
  181. package/dist/docs/guide/behaviour-data-binding/component-input.md +79 -0
  182. package/dist/docs/guide/behaviour-data-binding/dropdown-input.md +53 -0
  183. package/dist/docs/guide/behaviour-data-binding/entity-input.md +100 -0
  184. package/dist/docs/guide/behaviour-data-binding/float-input.md +35 -0
  185. package/dist/docs/guide/behaviour-data-binding/index.md +158 -0
  186. package/dist/docs/guide/behaviour-data-binding/slider-input.md +37 -0
  187. package/dist/docs/guide/behaviour-data-binding/text-input.md +35 -0
  188. package/dist/docs/guide/behaviour-data-binding/toggle-input.md +36 -0
  189. package/dist/docs/guide/behaviour-data-binding/vector2-input.md +36 -0
  190. package/dist/docs/guide/behaviour-data-binding/vector3-input.md +41 -0
  191. package/dist/docs/guide/components/parent-id.md +25 -0
  192. package/dist/docs/guide/runtime-entity-management.md +302 -0
  193. package/dist/docs/guide/scene/environment.md +5 -6
  194. package/dist/docs/guide/scene/index.md +5 -10
  195. package/dist/docs/guide/scene/postprocessing.md +5 -6
  196. package/dist/docs/guide/systems/object-management-system.md +61 -0
  197. package/dist/docs/guide/world-api.md +37 -1
  198. package/dist/factories/index.cjs.map +1 -1
  199. package/dist/factories/index.d.cts +2 -2
  200. package/dist/factories/index.d.ts +2 -2
  201. package/dist/factories/index.js +3 -3
  202. package/dist/{index-B5JcGMJ5.d.ts → index-BfoOC2CG.d.cts} +2 -2
  203. package/dist/{index-kx5O2mVU.d.cts → index-BoJ3_6a3.d.ts} +2 -2
  204. package/dist/index.cjs +65 -0
  205. package/dist/index.cjs.map +1 -1
  206. package/dist/index.d.cts +5 -5
  207. package/dist/index.d.ts +5 -5
  208. package/dist/index.js +73 -8
  209. package/dist/index.js.map +1 -1
  210. package/dist/systems/index.cjs.map +1 -1
  211. package/dist/systems/index.d.cts +2 -2
  212. package/dist/systems/index.d.ts +2 -2
  213. package/dist/systems/index.js +3 -3
  214. package/dist/types.d.cts +1 -1
  215. package/dist/types.d.ts +1 -1
  216. package/dist/worldSnapshotUtils.d.cts +1 -1
  217. package/dist/worldSnapshotUtils.d.ts +1 -1
  218. package/package.json +1 -1
  219. package/dist/chunk-XPCVEXMY.js.map +0 -1
  220. package/dist/docs/guide/inspector-data-binding.md +0 -367
@@ -1,5 +1,5 @@
1
- import { A as AnimationComponent, b as AudioComponent, c as CameraComponentOptions, C as CameraComponent, a1 as RigidbodyState, g as ColliderState, W as PhysicsComponent, w as EnvironmentState, q as Environment, p as EntityType, I as ImageComponent, y as ImageTargetAnchor, x as ImageTarget, L as LightComponent, M as MaterialComponent, P as MeshComponent, Q as MeshGeometryComponent, T as ModelComponent, U as Name, V as Object3DRef, _ as PostprocessingState, Z as Postprocessing, a4 as ScriptEntry, a3 as ScriptComponent, a5 as Selectable, a6 as SelectionTransformState, a7 as SpriteComponent, J as InstancedMeshKind, R as MeshGeometryParameters, H as InstancedMeshComponent, F as InstanceSlotComponent, ab as VideoComponent } from '../Video-ACTSfWjH.cjs';
2
- import { b as World, P as ParentId, T as TransformComponent, O as ObjectManagementSystem } from '../System-CHCucemW.cjs';
1
+ import { A as AnimationComponent, b as AudioComponent, c as CameraComponentOptions, C as CameraComponent, S as RigidbodyState, g as ColliderState, P as PhysicsComponent, n as EntityType, I as ImageComponent, p as ImageTargetAnchor, o as ImageTarget, L as LightComponent, M as MaterialComponent, z as MeshComponent, B as MeshGeometryComponent, H as ModelComponent, N as Name, O as Object3DRef, V as ScriptEntry, U as ScriptComponent, W as Selectable, X as SelectionTransformState, Y as SpriteComponent, v as InstancedMeshKind, F as MeshGeometryParameters, u as InstancedMeshComponent, s as InstanceSlotComponent, a0 as VideoComponent } from '../Video-D4B-z74P.cjs';
2
+ import { l as World, g as EnvironmentState, E as Environment, P as ParentId, i as PostprocessingState, h as Postprocessing, T as TransformComponent, O as ObjectManagementSystem } from '../System-BeuJ1xt5.cjs';
3
3
  import * as THREE from 'three';
4
4
  import '@dimforge/rapier3d-compat';
5
5
 
@@ -1,5 +1,5 @@
1
- import { A as AnimationComponent, b as AudioComponent, c as CameraComponentOptions, C as CameraComponent, a1 as RigidbodyState, g as ColliderState, W as PhysicsComponent, w as EnvironmentState, q as Environment, p as EntityType, I as ImageComponent, y as ImageTargetAnchor, x as ImageTarget, L as LightComponent, M as MaterialComponent, P as MeshComponent, Q as MeshGeometryComponent, T as ModelComponent, U as Name, V as Object3DRef, _ as PostprocessingState, Z as Postprocessing, a4 as ScriptEntry, a3 as ScriptComponent, a5 as Selectable, a6 as SelectionTransformState, a7 as SpriteComponent, J as InstancedMeshKind, R as MeshGeometryParameters, H as InstancedMeshComponent, F as InstanceSlotComponent, ab as VideoComponent } from '../Video-B9ZKmBIT.js';
2
- import { b as World, P as ParentId, T as TransformComponent, O as ObjectManagementSystem } from '../System-CHCucemW.js';
1
+ import { A as AnimationComponent, b as AudioComponent, c as CameraComponentOptions, C as CameraComponent, S as RigidbodyState, g as ColliderState, P as PhysicsComponent, n as EntityType, I as ImageComponent, p as ImageTargetAnchor, o as ImageTarget, L as LightComponent, M as MaterialComponent, z as MeshComponent, B as MeshGeometryComponent, H as ModelComponent, N as Name, O as Object3DRef, V as ScriptEntry, U as ScriptComponent, W as Selectable, X as SelectionTransformState, Y as SpriteComponent, v as InstancedMeshKind, F as MeshGeometryParameters, u as InstancedMeshComponent, s as InstanceSlotComponent, a0 as VideoComponent } from '../Video-Cym2C52L.js';
2
+ import { l as World, g as EnvironmentState, E as Environment, P as ParentId, i as PostprocessingState, h as Postprocessing, T as TransformComponent, O as ObjectManagementSystem } from '../System-BeuJ1xt5.js';
3
3
  import * as THREE from 'three';
4
4
  import '@dimforge/rapier3d-compat';
5
5
 
@@ -1,6 +1,6 @@
1
- export { createAnimationComponent, createAudioComponent, createCameraComponent, createEntityTypeComponent, createEnvironmentComponent, createImageComponent, createImageTargetAnchorComponent, createImageTargetComponent, createInstanceSlotComponent, createInstancedMeshComponent, createLightComponent, createMaterialComponent, createMeshComponent, createMeshGeometryComponent, createModelComponent, createNameComponent, createObject3DRefComponent, createParentIdComponent, createPhysicsComponent, createPostprocessingComponent, createScriptComponent, createSelectableComponent, createSelectionTransformStateComponent, createSpriteComponent, createTransformComponent, createVideoComponent, registerDefaultComponentFactories, registerDefaultFactories } from '../chunk-ZCEMOTH4.js';
2
- import '../chunk-PH43YHUT.js';
3
- import '../chunk-XPCVEXMY.js';
1
+ export { createAnimationComponent, createAudioComponent, createCameraComponent, createEntityTypeComponent, createEnvironmentComponent, createImageComponent, createImageTargetAnchorComponent, createImageTargetComponent, createInstanceSlotComponent, createInstancedMeshComponent, createLightComponent, createMaterialComponent, createMeshComponent, createMeshGeometryComponent, createModelComponent, createNameComponent, createObject3DRefComponent, createParentIdComponent, createPhysicsComponent, createPostprocessingComponent, createScriptComponent, createSelectableComponent, createSelectionTransformStateComponent, createSpriteComponent, createTransformComponent, createVideoComponent, registerDefaultComponentFactories, registerDefaultFactories } from '../chunk-7QBONTBW.js';
2
+ import '../chunk-27RBPOVO.js';
3
+ import '../chunk-FTIQQK62.js';
4
4
  import '../chunk-OY7ZODZP.js';
5
5
  //# sourceMappingURL=index.js.map
6
6
  //# sourceMappingURL=index.js.map
@@ -1,5 +1,5 @@
1
- import { A as AnimationComponent, a as AnimationComponentOptions, b as AudioComponent, C as CameraComponent, c as CameraComponentOptions, d as CameraProjection, e as CameraRuntimeType, f as ColliderShape, g as ColliderState, h as CubeMeshParameters, D as DEFAULT_COLLIDER_STATE, i as DEFAULT_ENVIRONMENT_STATE, j as DEFAULT_INSTANCED_MESH_PARAMETERS, k as DEFAULT_INSTANCE_TRANSFORM, l as DEFAULT_MESH_GEOMETRY_PARAMETERS, m as DEFAULT_PHYSICS_STATE, n as DEFAULT_POSTPROCESSING_STATE, o as DEFAULT_RIGIDBODY_STATE, E as EditableMeshObjectKind, p as EntityType, q as Environment, r as EnvironmentFogState, s as EnvironmentFogType, t as EnvironmentGradientEffect, u as EnvironmentSkyboxState, v as EnvironmentSkyboxType, w as EnvironmentState, I as ImageComponent, x as ImageTarget, y as ImageTargetAnchor, z as ImageTargetAnchorOptions, B as ImageTargetReference, F as InstanceSlotComponent, G as InstanceTransform, H as InstancedMeshComponent, J as InstancedMeshKind, L as LightComponent, K as LightValueState, M as MaterialComponent, N as MaterialTypeValue, O as MaterialValueState, P as MeshComponent, Q as MeshGeometryComponent, R as MeshGeometryParameters, S as MeshGeometryParametersByKind, T as ModelComponent, U as Name, V as Object3DRef, W as PhysicsComponent, X as PhysicsState, Y as PlaneMeshParameters, Z as Postprocessing, _ as PostprocessingState, $ as RadiusHeightMeshParameters, a0 as RadiusMeshParameters, a1 as RigidbodyState, a2 as RigidbodyType, a3 as ScriptComponent, a4 as ScriptEntry, a5 as Selectable, a6 as SelectionTransformState, a7 as SpriteComponent, a8 as TextureFilteringValue, a9 as TransformModeValue, aa as TransformSpaceValue, ab as VideoComponent, ac as normalizePhysicsState } from './Video-B9ZKmBIT.js';
2
- import { P as ParentId, T as TransformComponent, a as TransformData, V as Vec3 } from './System-CHCucemW.js';
1
+ import { A as AnimationComponent, a as AnimationComponentOptions, b as AudioComponent, C as CameraComponent, c as CameraComponentOptions, d as CameraProjection, e as CameraRuntimeType, f as ColliderShape, g as ColliderState, h as CubeMeshParameters, D as DEFAULT_COLLIDER_STATE, i as DEFAULT_INSTANCED_MESH_PARAMETERS, j as DEFAULT_INSTANCE_TRANSFORM, k as DEFAULT_MESH_GEOMETRY_PARAMETERS, l as DEFAULT_PHYSICS_STATE, m as DEFAULT_RIGIDBODY_STATE, E as EditableMeshObjectKind, n as EntityType, I as ImageComponent, o as ImageTarget, p as ImageTargetAnchor, q as ImageTargetAnchorOptions, r as ImageTargetReference, s as InstanceSlotComponent, t as InstanceTransform, u as InstancedMeshComponent, v as InstancedMeshKind, L as LightComponent, w as LightValueState, M as MaterialComponent, x as MaterialTypeValue, y as MaterialValueState, z as MeshComponent, B as MeshGeometryComponent, F as MeshGeometryParameters, G as MeshGeometryParametersByKind, H as ModelComponent, N as Name, O as Object3DRef, P as PhysicsComponent, J as PhysicsState, K as PlaneMeshParameters, R as RadiusHeightMeshParameters, Q as RadiusMeshParameters, S as RigidbodyState, T as RigidbodyType, U as ScriptComponent, V as ScriptEntry, W as Selectable, X as SelectionTransformState, Y as SpriteComponent, Z as TextureFilteringValue, _ as TransformModeValue, $ as TransformSpaceValue, a0 as VideoComponent, a1 as normalizePhysicsState } from './Video-D4B-z74P.cjs';
2
+ import { D as DEFAULT_ENVIRONMENT_STATE, a as DEFAULT_POSTPROCESSING_STATE, E as Environment, b as EnvironmentFogState, c as EnvironmentFogType, d as EnvironmentGradientEffect, e as EnvironmentSkyboxState, f as EnvironmentSkyboxType, g as EnvironmentState, P as ParentId, h as Postprocessing, i as PostprocessingState, T as TransformComponent, j as TransformData, V as Vec3 } from './System-BeuJ1xt5.cjs';
3
3
 
4
4
  declare const index_AnimationComponent: typeof AnimationComponent;
5
5
  declare const index_AnimationComponentOptions: typeof AnimationComponentOptions;
@@ -1,5 +1,5 @@
1
- import { A as AnimationComponent, a as AnimationComponentOptions, b as AudioComponent, C as CameraComponent, c as CameraComponentOptions, d as CameraProjection, e as CameraRuntimeType, f as ColliderShape, g as ColliderState, h as CubeMeshParameters, D as DEFAULT_COLLIDER_STATE, i as DEFAULT_ENVIRONMENT_STATE, j as DEFAULT_INSTANCED_MESH_PARAMETERS, k as DEFAULT_INSTANCE_TRANSFORM, l as DEFAULT_MESH_GEOMETRY_PARAMETERS, m as DEFAULT_PHYSICS_STATE, n as DEFAULT_POSTPROCESSING_STATE, o as DEFAULT_RIGIDBODY_STATE, E as EditableMeshObjectKind, p as EntityType, q as Environment, r as EnvironmentFogState, s as EnvironmentFogType, t as EnvironmentGradientEffect, u as EnvironmentSkyboxState, v as EnvironmentSkyboxType, w as EnvironmentState, I as ImageComponent, x as ImageTarget, y as ImageTargetAnchor, z as ImageTargetAnchorOptions, B as ImageTargetReference, F as InstanceSlotComponent, G as InstanceTransform, H as InstancedMeshComponent, J as InstancedMeshKind, L as LightComponent, K as LightValueState, M as MaterialComponent, N as MaterialTypeValue, O as MaterialValueState, P as MeshComponent, Q as MeshGeometryComponent, R as MeshGeometryParameters, S as MeshGeometryParametersByKind, T as ModelComponent, U as Name, V as Object3DRef, W as PhysicsComponent, X as PhysicsState, Y as PlaneMeshParameters, Z as Postprocessing, _ as PostprocessingState, $ as RadiusHeightMeshParameters, a0 as RadiusMeshParameters, a1 as RigidbodyState, a2 as RigidbodyType, a3 as ScriptComponent, a4 as ScriptEntry, a5 as Selectable, a6 as SelectionTransformState, a7 as SpriteComponent, a8 as TextureFilteringValue, a9 as TransformModeValue, aa as TransformSpaceValue, ab as VideoComponent, ac as normalizePhysicsState } from './Video-ACTSfWjH.cjs';
2
- import { P as ParentId, T as TransformComponent, a as TransformData, V as Vec3 } from './System-CHCucemW.cjs';
1
+ import { A as AnimationComponent, a as AnimationComponentOptions, b as AudioComponent, C as CameraComponent, c as CameraComponentOptions, d as CameraProjection, e as CameraRuntimeType, f as ColliderShape, g as ColliderState, h as CubeMeshParameters, D as DEFAULT_COLLIDER_STATE, i as DEFAULT_INSTANCED_MESH_PARAMETERS, j as DEFAULT_INSTANCE_TRANSFORM, k as DEFAULT_MESH_GEOMETRY_PARAMETERS, l as DEFAULT_PHYSICS_STATE, m as DEFAULT_RIGIDBODY_STATE, E as EditableMeshObjectKind, n as EntityType, I as ImageComponent, o as ImageTarget, p as ImageTargetAnchor, q as ImageTargetAnchorOptions, r as ImageTargetReference, s as InstanceSlotComponent, t as InstanceTransform, u as InstancedMeshComponent, v as InstancedMeshKind, L as LightComponent, w as LightValueState, M as MaterialComponent, x as MaterialTypeValue, y as MaterialValueState, z as MeshComponent, B as MeshGeometryComponent, F as MeshGeometryParameters, G as MeshGeometryParametersByKind, H as ModelComponent, N as Name, O as Object3DRef, P as PhysicsComponent, J as PhysicsState, K as PlaneMeshParameters, R as RadiusHeightMeshParameters, Q as RadiusMeshParameters, S as RigidbodyState, T as RigidbodyType, U as ScriptComponent, V as ScriptEntry, W as Selectable, X as SelectionTransformState, Y as SpriteComponent, Z as TextureFilteringValue, _ as TransformModeValue, $ as TransformSpaceValue, a0 as VideoComponent, a1 as normalizePhysicsState } from './Video-Cym2C52L.js';
2
+ import { D as DEFAULT_ENVIRONMENT_STATE, a as DEFAULT_POSTPROCESSING_STATE, E as Environment, b as EnvironmentFogState, c as EnvironmentFogType, d as EnvironmentGradientEffect, e as EnvironmentSkyboxState, f as EnvironmentSkyboxType, g as EnvironmentState, P as ParentId, h as Postprocessing, i as PostprocessingState, T as TransformComponent, j as TransformData, V as Vec3 } from './System-BeuJ1xt5.js';
3
3
 
4
4
  declare const index_AnimationComponent: typeof AnimationComponent;
5
5
  declare const index_AnimationComponentOptions: typeof AnimationComponentOptions;
package/dist/index.cjs CHANGED
@@ -7414,6 +7414,8 @@ var _World = class _World {
7414
7414
  this.components = /* @__PURE__ */ new Map();
7415
7415
  this.inputSystem = null;
7416
7416
  this.objectManagementSystem = null;
7417
+ this.environmentSyncSystem = null;
7418
+ this.postprocessingSyncSystem = null;
7417
7419
  this.rapierModule = null;
7418
7420
  this.rapierModulePromise = null;
7419
7421
  this.physicsWorld = null;
@@ -7794,6 +7796,8 @@ var _World = class _World {
7794
7796
  }
7795
7797
  this.isEditor = isEditor ?? false;
7796
7798
  this.objectManagementSystem = objectManagementSystem;
7799
+ this.environmentSyncSystem = environmentSyncSystem;
7800
+ this.postprocessingSyncSystem = postprocessingSyncSystem;
7797
7801
  return {
7798
7802
  objectManagementSystem,
7799
7803
  transformSyncSystem,
@@ -7944,6 +7948,24 @@ var _World = class _World {
7944
7948
  }
7945
7949
  return this.toEntityView(entityId);
7946
7950
  }
7951
+ getEntitiesChildren(entityId) {
7952
+ const children = [];
7953
+ const entitiesWithParent = this.query(ParentId);
7954
+ for (const childId of entitiesWithParent) {
7955
+ const parentIdComponent = this.getComponent(childId, ParentId);
7956
+ if (parentIdComponent?.value === entityId) {
7957
+ children.push(this.toEntityView(childId));
7958
+ }
7959
+ }
7960
+ return children;
7961
+ }
7962
+ getEntitiesParent(entityId) {
7963
+ const parentIdComponent = this.getComponent(entityId, ParentId);
7964
+ if (!parentIdComponent || parentIdComponent.value === null) {
7965
+ return null;
7966
+ }
7967
+ return this.getEntityById(parentIdComponent.value);
7968
+ }
7947
7969
  getObjectManagementSystem() {
7948
7970
  if (this.objectManagementSystem) return this.objectManagementSystem;
7949
7971
  const objectManagementSystem = this.systems.find(
@@ -7952,6 +7974,49 @@ var _World = class _World {
7952
7974
  this.objectManagementSystem = objectManagementSystem;
7953
7975
  return this.objectManagementSystem;
7954
7976
  }
7977
+ /**
7978
+ * Returns the singleton {@link Environment} component for the scene, or
7979
+ * `undefined` if no environment entity exists yet.
7980
+ *
7981
+ * Mutate `component.values` directly to change skybox, fog, or gravity at
7982
+ * runtime — `EnvironmentSyncSystem` picks up the changes next frame.
7983
+ *
7984
+ * @example
7985
+ * ```ts
7986
+ * const env = this.world.getEnvironmentComponent();
7987
+ * if (env) {
7988
+ * env.values.fog.type = "exponential";
7989
+ * env.values.fog.exponential.density = 0.01;
7990
+ * }
7991
+ * ```
7992
+ */
7993
+ getEnvironmentComponent() {
7994
+ const entityId = this.query(Environment)[0];
7995
+ if (entityId === void 0) return void 0;
7996
+ return this.getComponent(entityId, Environment);
7997
+ }
7998
+ /**
7999
+ * Returns the singleton {@link Postprocessing} component for the scene, or
8000
+ * `undefined` if no postprocessing entity exists yet.
8001
+ *
8002
+ * Mutate `component.values` directly to enable/disable effects or tweak
8003
+ * parameters at runtime — `PostprocessingSyncSystem` picks up the changes
8004
+ * next frame.
8005
+ *
8006
+ * @example
8007
+ * ```ts
8008
+ * const pp = this.world.getPostprocessingComponent();
8009
+ * if (pp) {
8010
+ * pp.values.bloom.enabled = true;
8011
+ * pp.values.bloom.intensity = 2.0;
8012
+ * }
8013
+ * ```
8014
+ */
8015
+ getPostprocessingComponent() {
8016
+ const entityId = this.query(Postprocessing)[0];
8017
+ if (entityId === void 0) return void 0;
8018
+ return this.getComponent(entityId, Postprocessing);
8019
+ }
7955
8020
  /**
7956
8021
  * Cast a ray from `origin` along `direction` and return every intersected
7957
8022
  * entity-bound mesh, sorted by distance. Each result is a standard