@relu-interactives/spatial-ecs 0.2.24 → 0.3.0
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.
- package/dist/{Video-ppAXaKt0.d.cts → Video-AIQYTAAr.d.cts} +15 -3
- package/dist/{Video-C1IOat7L.d.ts → Video-DlZ4G9ig.d.ts} +15 -3
- package/dist/{chunk-JHCPRVBC.js → chunk-7BPHZWQ6.js} +59 -17
- package/dist/chunk-7BPHZWQ6.js.map +1 -0
- package/dist/{chunk-CCE5K2TU.js → chunk-7JFSEV7A.js} +18 -13
- package/dist/chunk-7JFSEV7A.js.map +1 -0
- package/dist/{chunk-52CHDPRQ.js → chunk-AT5SPSPM.js} +4 -4
- package/dist/{chunk-52CHDPRQ.js.map → chunk-AT5SPSPM.js.map} +1 -1
- package/dist/{chunk-ZXGHKX7N.js → chunk-OWQSESTO.js} +12 -2
- package/dist/chunk-OWQSESTO.js.map +1 -0
- package/dist/{chunk-WKGCC7YL.js → chunk-PZ4CAALA.js} +3 -3
- package/dist/{chunk-WKGCC7YL.js.map → chunk-PZ4CAALA.js.map} +1 -1
- package/dist/components/index.cjs +55 -13
- package/dist/components/index.cjs.map +1 -1
- package/dist/components/index.d.cts +2 -2
- package/dist/components/index.d.ts +2 -2
- package/dist/components/index.js +1 -1
- package/dist/docs/api/Behaviour/classes/Behaviour.md +98 -51
- package/dist/docs/api/Component/classes/Component.md +4 -1
- package/dist/docs/api/components/classes/AnimationComponent.md +26 -26
- package/dist/docs/api/components/classes/AudioComponent.md +19 -19
- package/dist/docs/api/components/classes/CameraComponent.md +14 -14
- package/dist/docs/api/components/classes/EntityType.md +4 -4
- package/dist/docs/api/components/classes/Environment.md +3 -3
- package/dist/docs/api/components/classes/ImageComponent.md +7 -7
- package/dist/docs/api/components/classes/ImageTarget.md +7 -7
- package/dist/docs/api/components/classes/ImageTargetAnchor.md +4 -4
- package/dist/docs/api/components/classes/InstanceSlotComponent.md +4 -4
- package/dist/docs/api/components/classes/InstancedMeshComponent.md +10 -10
- package/dist/docs/api/components/classes/LightComponent.md +6 -6
- package/dist/docs/api/components/classes/MaterialComponent.md +57 -11
- package/dist/docs/api/components/classes/MeshComponent.md +3 -3
- package/dist/docs/api/components/classes/MeshGeometryComponent.md +9 -9
- package/dist/docs/api/components/classes/ModelComponent.md +4 -4
- package/dist/docs/api/components/classes/Name.md +3 -3
- package/dist/docs/api/components/classes/Object3DRef.md +4 -4
- package/dist/docs/api/components/classes/ParentId.md +3 -3
- package/dist/docs/api/components/classes/PhysicsComponent.md +12 -13
- package/dist/docs/api/components/classes/Postprocessing.md +3 -3
- package/dist/docs/api/components/classes/PrefabInstance.md +80 -0
- package/dist/docs/api/components/classes/PrefabNode.md +54 -0
- package/dist/docs/api/components/classes/ScriptComponent.md +5 -5
- package/dist/docs/api/components/classes/ScriptObjectComponent.md +55 -0
- package/dist/docs/api/components/classes/Selectable.md +3 -3
- package/dist/docs/api/components/classes/SelectionTransformState.md +5 -5
- package/dist/docs/api/components/classes/SpriteComponent.md +7 -7
- package/dist/docs/api/components/classes/TransformComponent.md +12 -12
- package/dist/docs/api/components/classes/VideoComponent.md +28 -28
- package/dist/docs/api/components/functions/defaultMaterialValue.md +17 -0
- package/dist/docs/api/components/functions/normalizePhysicsState.md +1 -1
- package/dist/docs/api/components/functions/setPhysicsLiveRef.md +34 -0
- package/dist/docs/api/components/index.md +8 -1
- package/dist/docs/api/components/type-aliases/AnimationComponentOptions.md +9 -9
- package/dist/docs/api/components/type-aliases/CameraComponentOptions.md +13 -13
- package/dist/docs/api/components/type-aliases/CameraProjection.md +1 -1
- package/dist/docs/api/components/type-aliases/CameraRuntimeType.md +1 -1
- package/dist/docs/api/components/type-aliases/ColliderShape.md +1 -1
- package/dist/docs/api/components/type-aliases/ColliderState.md +20 -20
- package/dist/docs/api/components/type-aliases/CubeMeshParameters.md +4 -4
- package/dist/docs/api/components/type-aliases/EditableMeshObjectKind.md +1 -1
- package/dist/docs/api/components/type-aliases/EnvironmentFogState.md +8 -8
- package/dist/docs/api/components/type-aliases/EnvironmentFogType.md +1 -1
- package/dist/docs/api/components/type-aliases/EnvironmentGradientEffect.md +1 -1
- package/dist/docs/api/components/type-aliases/EnvironmentSkyboxState.md +7 -7
- package/dist/docs/api/components/type-aliases/EnvironmentSkyboxType.md +1 -1
- package/dist/docs/api/components/type-aliases/EnvironmentState.md +5 -5
- package/dist/docs/api/components/type-aliases/ImageTargetAnchorOptions.md +3 -3
- package/dist/docs/api/components/type-aliases/ImageTargetReference.md +7 -7
- package/dist/docs/api/components/type-aliases/InstanceTransform.md +13 -13
- package/dist/docs/api/components/type-aliases/InstancedMeshKind.md +1 -1
- package/dist/docs/api/components/type-aliases/LightValueState.md +11 -11
- package/dist/docs/api/components/type-aliases/MaterialTypeValue.md +1 -1
- package/dist/docs/api/components/type-aliases/MaterialValueState.md +28 -28
- package/dist/docs/api/components/type-aliases/MeshGeometryParameters.md +1 -1
- package/dist/docs/api/components/type-aliases/MeshGeometryParametersByKind.md +7 -7
- package/dist/docs/api/components/type-aliases/PhysicsState.md +3 -3
- package/dist/docs/api/components/type-aliases/PlaneMeshParameters.md +3 -3
- package/dist/docs/api/components/type-aliases/PostprocessingState.md +62 -62
- package/dist/docs/api/components/type-aliases/RadiusHeightMeshParameters.md +3 -3
- package/dist/docs/api/components/type-aliases/RadiusMeshParameters.md +2 -2
- package/dist/docs/api/components/type-aliases/RigidbodyState.md +17 -17
- package/dist/docs/api/components/type-aliases/RigidbodyType.md +1 -1
- package/dist/docs/api/components/type-aliases/ScriptEntry.md +8 -10
- package/dist/docs/api/components/type-aliases/ScriptObjectComponentInput.md +20 -0
- package/dist/docs/api/components/type-aliases/ScriptObjectRuntimeState.md +13 -0
- package/dist/docs/api/components/type-aliases/TextureFilteringValue.md +1 -1
- package/dist/docs/api/components/type-aliases/TransformData.md +4 -4
- package/dist/docs/api/components/type-aliases/TransformModeValue.md +1 -1
- package/dist/docs/api/components/type-aliases/TransformSpaceValue.md +1 -1
- package/dist/docs/api/components/type-aliases/Vec3.md +4 -4
- package/dist/docs/api/components/variables/DEFAULT_COLLIDER_STATE.md +1 -1
- package/dist/docs/api/components/variables/DEFAULT_ENVIRONMENT_STATE.md +1 -1
- package/dist/docs/api/components/variables/DEFAULT_INSTANCED_MESH_PARAMETERS.md +1 -1
- package/dist/docs/api/components/variables/DEFAULT_INSTANCE_TRANSFORM.md +1 -1
- package/dist/docs/api/components/variables/DEFAULT_MESH_GEOMETRY_PARAMETERS.md +1 -1
- package/dist/docs/api/components/variables/DEFAULT_PHYSICS_STATE.md +1 -1
- package/dist/docs/api/components/variables/DEFAULT_POSTPROCESSING_STATE.md +1 -1
- package/dist/docs/api/components/variables/DEFAULT_RIGIDBODY_STATE.md +1 -1
- package/dist/docs/api/index/classes/AnimationStateMachine.md +16 -16
- package/dist/docs/api/index/classes/AnimationStateManager.md +13 -13
- package/dist/docs/api/index/classes/AnimationSystem.md +3 -3
- package/dist/docs/api/index/classes/AudioSystem.md +4 -4
- package/dist/docs/api/index/classes/CameraSyncSystem.md +2 -2
- package/dist/docs/api/index/classes/EnvironmentSyncSystem.md +4 -4
- package/dist/docs/api/index/classes/InputSystem.md +33 -33
- package/dist/docs/api/index/classes/InstancedMeshSystem.md +2 -2
- package/dist/docs/api/index/classes/LightSyncSystem.md +2 -2
- package/dist/docs/api/index/classes/MaterialSyncSystem.md +3 -3
- package/dist/docs/api/index/classes/MeshGeometrySystem.md +2 -2
- package/dist/docs/api/index/classes/ObjectManagementSystem.md +14 -14
- package/dist/docs/api/index/classes/ObjectVisibilitySystem.md +2 -2
- package/dist/docs/api/index/classes/PhysicsSyncSystem.md +4 -4
- package/dist/docs/api/index/classes/PostprocessingSyncSystem.md +4 -4
- package/dist/docs/api/index/classes/RenderSystem.md +3 -3
- package/dist/docs/api/index/classes/ScriptBehaviourSystem.md +5 -5
- package/dist/docs/api/index/classes/ScriptObject.md +156 -0
- package/dist/docs/api/index/classes/ScriptObjectSystem.md +129 -0
- package/dist/docs/api/index/classes/TransformSyncSystem.md +2 -2
- package/dist/docs/api/index/classes/VideoSystem.md +4 -4
- package/dist/docs/api/index/classes/World.md +183 -86
- package/dist/docs/api/index/functions/applyPrefabToSnapshotInstances.md +32 -0
- package/dist/docs/api/index/functions/buildComponentValueMaps.md +23 -0
- package/dist/docs/api/index/functions/buildNodeKeyMapsFromSnapshot.md +25 -0
- package/dist/docs/api/index/functions/buildNodeMapsFromSnapshot.md +23 -0
- package/dist/docs/api/index/functions/canonicalizeComponentValue.md +38 -0
- package/dist/docs/api/index/functions/clearModelCache.md +26 -0
- package/dist/docs/api/index/functions/clearPrefabCache.md +25 -0
- package/dist/docs/api/index/functions/collectDiffPaths.md +38 -0
- package/dist/docs/api/index/functions/collectDirectPrefabDependencies.md +27 -0
- package/dist/docs/api/index/functions/collectEntitySubtree.md +29 -0
- package/dist/docs/api/index/functions/collectSnapshotSubtreeIds.md +26 -0
- package/dist/docs/api/index/functions/computeInstanceOverrides.md +44 -0
- package/dist/docs/api/index/functions/createAnimationComponent.md +1 -1
- package/dist/docs/api/index/functions/createAudioComponent.md +1 -1
- package/dist/docs/api/index/functions/createCameraComponent.md +1 -1
- package/dist/docs/api/index/functions/createEntityTypeComponent.md +2 -2
- package/dist/docs/api/index/functions/createEnvironmentComponent.md +1 -1
- package/dist/docs/api/index/functions/createImageComponent.md +1 -1
- package/dist/docs/api/index/functions/createImageTargetAnchorComponent.md +1 -1
- package/dist/docs/api/index/functions/createImageTargetComponent.md +1 -1
- package/dist/docs/api/index/functions/createInstanceSlotComponent.md +1 -1
- package/dist/docs/api/index/functions/createInstancedMeshComponent.md +1 -1
- package/dist/docs/api/index/functions/createLightComponent.md +1 -1
- package/dist/docs/api/index/functions/createMaterialComponent.md +1 -1
- package/dist/docs/api/index/functions/createMeshComponent.md +1 -1
- package/dist/docs/api/index/functions/createMeshGeometryComponent.md +1 -1
- package/dist/docs/api/index/functions/createModelComponent.md +1 -1
- package/dist/docs/api/index/functions/createNameComponent.md +1 -1
- package/dist/docs/api/index/functions/createObject3DRefComponent.md +1 -1
- package/dist/docs/api/index/functions/createParentIdComponent.md +1 -1
- package/dist/docs/api/index/functions/createPhysicsComponent.md +2 -4
- package/dist/docs/api/index/functions/createPostprocessingComponent.md +1 -1
- package/dist/docs/api/index/functions/createScriptComponent.md +1 -1
- package/dist/docs/api/index/functions/createScriptObjectComponent.md +28 -0
- package/dist/docs/api/index/functions/createSelectableComponent.md +1 -1
- package/dist/docs/api/index/functions/createSelectionTransformStateComponent.md +1 -1
- package/dist/docs/api/index/functions/createSpriteComponent.md +1 -1
- package/dist/docs/api/index/functions/createTransformComponent.md +1 -1
- package/dist/docs/api/index/functions/createVideoComponent.md +1 -1
- package/dist/docs/api/index/functions/decanonicalizeComponentValue.md +28 -0
- package/dist/docs/api/index/functions/despawnPrefab.md +32 -0
- package/dist/docs/api/index/functions/encodeOverride.md +28 -0
- package/dist/docs/api/index/functions/findSnapshotRootEntityIds.md +25 -0
- package/dist/docs/api/index/functions/findTopLevelNestedRegions.md +28 -0
- package/dist/docs/api/index/functions/groupOverridePaths.md +25 -0
- package/dist/docs/api/index/functions/hydrateWorldFromSnapshot.md +1 -1
- package/dist/docs/api/index/functions/hydrateWorldFromSnapshotDetailed.md +4 -2
- package/dist/docs/api/index/functions/indexSnapshotByEntity.md +25 -0
- package/dist/docs/api/index/functions/instantiateSubtree.md +32 -0
- package/dist/docs/api/index/functions/loadPrefab.md +28 -0
- package/dist/docs/api/index/functions/loadSharedGltf.md +29 -0
- package/dist/docs/api/index/functions/mergeComponentValue.md +32 -0
- package/dist/docs/api/index/functions/parseOverride.md +34 -0
- package/dist/docs/api/index/functions/parsePrefabAsset.md +25 -0
- package/dist/docs/api/index/functions/prefabFileVersionFor.md +25 -0
- package/dist/docs/api/index/functions/registerDefaultComponentFactories.md +1 -1
- package/dist/docs/api/index/functions/registerDefaultFactories.md +1 -1
- package/dist/docs/api/index/functions/remapSnapshotEntityIds.md +46 -0
- package/dist/docs/api/index/functions/resolveDracoDecoderPath.md +17 -0
- package/dist/docs/api/index/functions/restoreComponentState.md +34 -0
- package/dist/docs/api/index/functions/restorePostCreateComponents.md +36 -0
- package/dist/docs/api/index/functions/serializeEntitySubtree.md +35 -0
- package/dist/docs/api/index/functions/setDracoDecoderPath.md +30 -0
- package/dist/docs/api/index/functions/setPrefabAssetUrlResolver.md +30 -0
- package/dist/docs/api/index/functions/spawnPrefab.md +36 -0
- package/dist/docs/api/index/index.md +65 -0
- package/dist/docs/api/index/interfaces/EcsSystem.md +3 -3
- package/dist/docs/api/index/interfaces/StateMachine.md +13 -13
- package/dist/docs/api/index/type-aliases/AnimationStateCallbacks.md +4 -4
- package/dist/docs/api/index/type-aliases/ApplyPrefabToSnapshotResult.md +23 -0
- package/dist/docs/api/index/type-aliases/ComponentFactory.md +1 -1
- package/dist/docs/api/index/type-aliases/ComponentValueMaps.md +69 -0
- package/dist/docs/api/index/type-aliases/EcsComponentFactoryKind.md +2 -1
- package/dist/docs/api/index/type-aliases/EcsWorldComponentSnapshot.md +3 -3
- package/dist/docs/api/index/type-aliases/EcsWorldStateSnapshotLike.md +4 -4
- package/dist/docs/api/index/type-aliases/ExternalRefWarning.md +27 -0
- package/dist/docs/api/index/type-aliases/HydrateOptions.md +27 -0
- package/dist/docs/api/index/type-aliases/HydrateWorldFromSnapshotResult.md +7 -5
- package/dist/docs/api/index/type-aliases/InstantiateSubtreeResult.md +23 -0
- package/dist/docs/api/index/type-aliases/KeyboardKey.md +1 -1
- package/dist/docs/api/index/type-aliases/ModuleLoader.md +25 -0
- package/dist/docs/api/index/type-aliases/MouseButton.md +1 -1
- package/dist/docs/api/index/type-aliases/NestedRegion.md +27 -0
- package/dist/docs/api/index/type-aliases/NodeKeyMaps.md +30 -0
- package/dist/docs/api/index/type-aliases/NodeMaps.md +25 -0
- package/dist/docs/api/index/type-aliases/PrefabAsset.md +32 -0
- package/dist/docs/api/index/type-aliases/RemapSnapshotOptions.md +21 -0
- package/dist/docs/api/index/type-aliases/SelectionContext.md +4 -4
- package/dist/docs/api/index/type-aliases/SerializeEntitySubtreeResult.md +25 -0
- package/dist/docs/api/index/type-aliases/SpawnPrefabOptions.md +27 -0
- package/dist/docs/api/index/type-aliases/SpawnPrefabSource.md +19 -0
- package/dist/docs/api/index/type-aliases/SubtreeSnapshot.md +43 -0
- package/dist/docs/api/index/variables/ADDED_NODE_MARKER_COMPONENT.md +19 -0
- package/dist/docs/api/index/variables/HYDRATABLE_ENTITY_KINDS.md +1 -1
- package/dist/docs/api/index/variables/KeyboardKeys.md +89 -89
- package/dist/docs/api/index/variables/NODE_KEY_SEPARATOR.md +13 -0
- package/dist/docs/api/index/variables/OVERRIDE_DIFF_EXCLUDED_COMPONENTS.md +15 -0
- package/dist/docs/api/index/variables/OVERRIDE_ROOT_EXCLUDED_COMPONENTS.md +16 -0
- package/dist/docs/api/index/variables/PREFAB_FILE_VERSION.md +13 -0
- package/dist/docs/api/index/variables/PREFAB_FILE_VERSION_NESTED.md +15 -0
- package/dist/docs/api/index/variables/SCRIPT_OBJECT_ROOT_FLAG.md +15 -0
- package/dist/docs/api/index/variables/SHARED_MODEL_RESOURCE_FLAG.md +17 -0
- package/dist/docs/api/typedoc-sidebar.json +1 -1
- package/dist/docs/api/types/type-aliases/AssetInput.md +3 -3
- package/dist/docs/api/types/type-aliases/CheckboxInput.md +3 -3
- package/dist/docs/api/types/type-aliases/ColorInput.md +1 -1
- package/dist/docs/api/types/type-aliases/ComponentInput.md +4 -4
- package/dist/docs/api/types/type-aliases/ComponentKind.md +2 -1
- package/dist/docs/api/types/type-aliases/DropdownInput.md +3 -3
- package/dist/docs/api/types/type-aliases/DropdownOption.md +3 -3
- package/dist/docs/api/types/type-aliases/EcsEntityEditorKind.md +1 -1
- package/dist/docs/api/types/type-aliases/EcsEntityKind.md +3 -2
- package/dist/docs/api/types/type-aliases/EntityId.md +1 -1
- package/dist/docs/api/types/type-aliases/EntityInput.md +3 -3
- package/dist/docs/api/types/type-aliases/FloatInput.md +1 -1
- package/dist/docs/api/types/type-aliases/IntersectionResult.md +3 -3
- package/dist/docs/api/types/type-aliases/ParentLookup.md +3 -3
- package/dist/docs/api/types/type-aliases/SelectionListener.md +1 -1
- package/dist/docs/api/types/type-aliases/SliderInput.md +5 -5
- package/dist/docs/api/types/type-aliases/TextInput.md +1 -1
- package/dist/docs/api/types/type-aliases/ToggleInput.md +1 -1
- package/dist/docs/api/types/type-aliases/Vec3.md +1 -1
- package/dist/docs/api/types/type-aliases/Vector2Input.md +3 -3
- package/dist/docs/api/types/type-aliases/Vector3Input.md +4 -4
- package/dist/docs/api/types/type-aliases/WorldEntityView.md +1 -1
- package/dist/docs/guide/components/_sidebar.json +4 -0
- package/dist/docs/guide/components/material.md +1 -0
- package/dist/docs/guide/components/script-object.md +32 -0
- package/dist/factories/index.cjs +54 -13
- package/dist/factories/index.cjs.map +1 -1
- package/dist/factories/index.d.cts +1 -1
- package/dist/factories/index.d.ts +1 -1
- package/dist/factories/index.js +3 -3
- package/dist/{index-DdiWu1b6.d.ts → index-BwiRJNIT.d.ts} +3 -2
- package/dist/{index-Cu2Pt7wN.d.cts → index-Gr8aCPRM.d.cts} +3 -2
- package/dist/index.cjs +80 -23
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +9 -9
- package/dist/systems/index.cjs +68 -22
- package/dist/systems/index.cjs.map +1 -1
- package/dist/systems/index.js +3 -3
- package/dist/worldSnapshotUtils.cjs +10 -0
- package/dist/worldSnapshotUtils.cjs.map +1 -1
- package/dist/worldSnapshotUtils.js +1 -1
- package/package.json +4 -4
- package/dist/chunk-CCE5K2TU.js.map +0 -1
- package/dist/chunk-JHCPRVBC.js.map +0 -1
- package/dist/chunk-ZXGHKX7N.js.map +0 -1
|
@@ -18,7 +18,7 @@ type ComponentInput<T> = {
|
|
|
18
18
|
};
|
|
19
19
|
```
|
|
20
20
|
|
|
21
|
-
Defined in: [types.ts:
|
|
21
|
+
Defined in: [types.ts:111](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L111)
|
|
22
22
|
|
|
23
23
|
Inspector field that lets the user drag an entity and optionally pick a
|
|
24
24
|
component from it.
|
|
@@ -47,6 +47,6 @@ transform: { type: "component", componentKind: "Transform", value: null } as Com
|
|
|
47
47
|
|
|
48
48
|
| Property | Type | Description | Defined in |
|
|
49
49
|
| ------ | ------ | ------ | ------ |
|
|
50
|
-
| <a id="type"></a> `type` | `"component"` | - | [types.ts:
|
|
51
|
-
| <a id="componentkind"></a> `componentKind?` | [`ComponentKind`](ComponentKind.md) | Optional component-kind constraint. When provided, the inspector skips the dropdown and resolves directly to this kind. | [types.ts:
|
|
52
|
-
| <a id="value"></a> `value` | \| \{ `entityId`: [`EntityId`](EntityId.md); `componentKind`: [`ComponentKind`](ComponentKind.md); \} \| `null` | - | [types.ts:
|
|
50
|
+
| <a id="type"></a> `type` | `"component"` | - | [types.ts:112](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L112) |
|
|
51
|
+
| <a id="componentkind"></a> `componentKind?` | [`ComponentKind`](ComponentKind.md) | Optional component-kind constraint. When provided, the inspector skips the dropdown and resolves directly to this kind. | [types.ts:115](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L115) |
|
|
52
|
+
| <a id="value"></a> `value` | \| \{ `entityId`: [`EntityId`](EntityId.md); `componentKind`: [`ComponentKind`](ComponentKind.md); \} \| `null` | - | [types.ts:116](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L116) |
|
|
@@ -29,6 +29,7 @@ type ComponentKind =
|
|
|
29
29
|
| "Physics"
|
|
30
30
|
| "Postprocessing"
|
|
31
31
|
| "Script"
|
|
32
|
+
| "ScriptObject"
|
|
32
33
|
| "Selectable"
|
|
33
34
|
| "SelectionTransformState"
|
|
34
35
|
| "Sprite"
|
|
@@ -36,4 +37,4 @@ type ComponentKind =
|
|
|
36
37
|
| "Video";
|
|
37
38
|
```
|
|
38
39
|
|
|
39
|
-
Defined in: [types.ts:
|
|
40
|
+
Defined in: [types.ts:68](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L68)
|
|
@@ -13,11 +13,11 @@ type DropdownInput = {
|
|
|
13
13
|
};
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
Defined in: [types.ts:
|
|
16
|
+
Defined in: [types.ts:63](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L63)
|
|
17
17
|
|
|
18
18
|
## Properties
|
|
19
19
|
|
|
20
20
|
| Property | Type | Defined in |
|
|
21
21
|
| ------ | ------ | ------ |
|
|
22
|
-
| <a id="options"></a> `options` | [`DropdownOption`](DropdownOption.md)[] | [types.ts:
|
|
23
|
-
| <a id="value"></a> `value` | `string` \| `any` | [types.ts:
|
|
22
|
+
| <a id="options"></a> `options` | [`DropdownOption`](DropdownOption.md)[] | [types.ts:63](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L63) |
|
|
23
|
+
| <a id="value"></a> `value` | `string` \| `any` | [types.ts:63](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L63) |
|
|
@@ -13,11 +13,11 @@ type DropdownOption = {
|
|
|
13
13
|
};
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
Defined in: [types.ts:
|
|
16
|
+
Defined in: [types.ts:62](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L62)
|
|
17
17
|
|
|
18
18
|
## Properties
|
|
19
19
|
|
|
20
20
|
| Property | Type | Defined in |
|
|
21
21
|
| ------ | ------ | ------ |
|
|
22
|
-
| <a id="label"></a> `label` | `string` | [types.ts:
|
|
23
|
-
| <a id="value"></a> `value` | `string` \| `any` | [types.ts:
|
|
22
|
+
| <a id="label"></a> `label` | `string` | [types.ts:62](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L62) |
|
|
23
|
+
| <a id="value"></a> `value` | `string` \| `any` | [types.ts:62](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L62) |
|
|
@@ -10,6 +10,6 @@
|
|
|
10
10
|
type EcsEntityEditorKind = EcsEntityKind | "editorUtility";
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
-
Defined in: [types.ts:
|
|
13
|
+
Defined in: [types.ts:43](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L43)
|
|
14
14
|
|
|
15
15
|
[EcsEntityKind](EcsEntityKind.md) extended with editor-only utility entities (gizmos, helpers).
|
|
@@ -27,10 +27,11 @@ type EcsEntityKind =
|
|
|
27
27
|
| "spotLight"
|
|
28
28
|
| "areaLight"
|
|
29
29
|
| "instancedMesh"
|
|
30
|
-
| "instanceSlot"
|
|
30
|
+
| "instanceSlot"
|
|
31
|
+
| "scriptObject";
|
|
31
32
|
```
|
|
32
33
|
|
|
33
|
-
Defined in: [types.ts:19](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/
|
|
34
|
+
Defined in: [types.ts:19](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L19)
|
|
34
35
|
|
|
35
36
|
Built-in entity kinds recognized by the ECS factory registry. Each kind
|
|
36
37
|
maps to an object factory in `core/factories/objects/*` that creates the
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
type EntityId = number;
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
-
Defined in: [types.ts:12](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/
|
|
13
|
+
Defined in: [types.ts:12](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L12)
|
|
14
14
|
|
|
15
15
|
Numeric identifier for an entity. Entities are pure ids — all data lives in
|
|
16
16
|
components attached to the entity.
|
|
@@ -13,11 +13,11 @@ type EntityInput = {
|
|
|
13
13
|
};
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
Defined in: [types.ts:
|
|
16
|
+
Defined in: [types.ts:67](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L67)
|
|
17
17
|
|
|
18
18
|
## Properties
|
|
19
19
|
|
|
20
20
|
| Property | Type | Defined in |
|
|
21
21
|
| ------ | ------ | ------ |
|
|
22
|
-
| <a id="type"></a> `type` | `"entity"` | [types.ts:
|
|
23
|
-
| <a id="value"></a> `value` | [`EntityId`](EntityId.md) \| `null` | [types.ts:
|
|
22
|
+
| <a id="type"></a> `type` | `"entity"` | [types.ts:67](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L67) |
|
|
23
|
+
| <a id="value"></a> `value` | [`EntityId`](EntityId.md) \| `null` | [types.ts:67](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L67) |
|
|
@@ -10,4 +10,4 @@
|
|
|
10
10
|
type FloatInput = number;
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
-
Defined in: [types.ts:
|
|
13
|
+
Defined in: [types.ts:52](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L52)
|
|
@@ -13,7 +13,7 @@ type IntersectionResult = {
|
|
|
13
13
|
};
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
Defined in: [types.ts:
|
|
16
|
+
Defined in: [types.ts:157](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L157)
|
|
17
17
|
|
|
18
18
|
Single hit returned by `World.raycast` / `World.raycastFrom`. Pairs the
|
|
19
19
|
standard `THREE.Intersection` (`threeResult`) with the owning entity id
|
|
@@ -25,5 +25,5 @@ editor helper).
|
|
|
25
25
|
|
|
26
26
|
| Property | Type | Description | Defined in |
|
|
27
27
|
| ------ | ------ | ------ | ------ |
|
|
28
|
-
| <a id="entityid"></a> `entityId` | [`EntityId`](EntityId.md) \| `null` | The entity that owns the hit object, or `null` if untracked. | [types.ts:
|
|
29
|
-
| <a id="threeresult"></a> `threeResult` | `THREE.Intersection` | The underlying three.js intersection record. | [types.ts:
|
|
28
|
+
| <a id="entityid"></a> `entityId` | [`EntityId`](EntityId.md) \| `null` | The entity that owns the hit object, or `null` if untracked. | [types.ts:159](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L159) |
|
|
29
|
+
| <a id="threeresult"></a> `threeResult` | `THREE.Intersection` | The underlying three.js intersection record. | [types.ts:161](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L161) |
|
|
@@ -13,7 +13,7 @@ type ParentLookup = {
|
|
|
13
13
|
};
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
Defined in: [types.ts:
|
|
16
|
+
Defined in: [types.ts:134](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L134)
|
|
17
17
|
|
|
18
18
|
Result of a parent lookup. `parent` is `null` for entities at the root or
|
|
19
19
|
for entities without a [ParentId](../../components/classes/ParentId.md) component.
|
|
@@ -22,5 +22,5 @@ for entities without a [ParentId](../../components/classes/ParentId.md) componen
|
|
|
22
22
|
|
|
23
23
|
| Property | Type | Description | Defined in |
|
|
24
24
|
| ------ | ------ | ------ | ------ |
|
|
25
|
-
| <a id="parentidcomponent"></a> `parentIdComponent` | [`ParentId`](../../components/classes/ParentId.md) \| `null` | The entity's `ParentId` component, or `null` if it has none. | [types.ts:
|
|
26
|
-
| <a id="parent"></a> `parent` | [`WorldEntityView`](WorldEntityView.md) \| `null` | The resolved parent entity view, or `null` if the entity is at the root. | [types.ts:
|
|
25
|
+
| <a id="parentidcomponent"></a> `parentIdComponent` | [`ParentId`](../../components/classes/ParentId.md) \| `null` | The entity's `ParentId` component, or `null` if it has none. | [types.ts:136](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L136) |
|
|
26
|
+
| <a id="parent"></a> `parent` | [`WorldEntityView`](WorldEntityView.md) \| `null` | The resolved parent entity view, or `null` if the entity is at the root. | [types.ts:138](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L138) |
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
type SelectionListener = (entityId) => void;
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
-
Defined in: [types.ts:
|
|
13
|
+
Defined in: [types.ts:46](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L46)
|
|
14
14
|
|
|
15
15
|
Callback invoked when the selected entity changes. `null` indicates a deselection.
|
|
16
16
|
|
|
@@ -15,13 +15,13 @@ type SliderInput = {
|
|
|
15
15
|
};
|
|
16
16
|
```
|
|
17
17
|
|
|
18
|
-
Defined in: [types.ts:
|
|
18
|
+
Defined in: [types.ts:56](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L56)
|
|
19
19
|
|
|
20
20
|
## Properties
|
|
21
21
|
|
|
22
22
|
| Property | Type | Defined in |
|
|
23
23
|
| ------ | ------ | ------ |
|
|
24
|
-
| <a id="min"></a> `min` | `number` | [types.ts:
|
|
25
|
-
| <a id="max"></a> `max` | `number` | [types.ts:
|
|
26
|
-
| <a id="step"></a> `step` | `number` | [types.ts:
|
|
27
|
-
| <a id="value"></a> `value` | `number` | [types.ts:
|
|
24
|
+
| <a id="min"></a> `min` | `number` | [types.ts:57](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L57) |
|
|
25
|
+
| <a id="max"></a> `max` | `number` | [types.ts:58](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L58) |
|
|
26
|
+
| <a id="step"></a> `step` | `number` | [types.ts:59](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L59) |
|
|
27
|
+
| <a id="value"></a> `value` | `number` | [types.ts:60](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L60) |
|
|
@@ -10,4 +10,4 @@
|
|
|
10
10
|
type TextInput = string;
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
-
Defined in: [types.ts:
|
|
13
|
+
Defined in: [types.ts:51](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L51)
|
|
@@ -10,4 +10,4 @@
|
|
|
10
10
|
type ToggleInput = boolean;
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
-
Defined in: [types.ts:
|
|
13
|
+
Defined in: [types.ts:65](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L65)
|
|
@@ -16,7 +16,7 @@ type Vec3 =
|
|
|
16
16
|
};
|
|
17
17
|
```
|
|
18
18
|
|
|
19
|
-
Defined in: [types.ts:
|
|
19
|
+
Defined in: [types.ts:146](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L146)
|
|
20
20
|
|
|
21
21
|
Loose 3D vector accepted by raycast and other spatial helpers. Either a
|
|
22
22
|
live `THREE.Vector3` or a plain `{ x, y, z }` object — both are normalized
|
|
@@ -13,11 +13,11 @@ type Vector2Input = {
|
|
|
13
13
|
};
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
Defined in: [types.ts:
|
|
16
|
+
Defined in: [types.ts:54](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L54)
|
|
17
17
|
|
|
18
18
|
## Properties
|
|
19
19
|
|
|
20
20
|
| Property | Type | Defined in |
|
|
21
21
|
| ------ | ------ | ------ |
|
|
22
|
-
| <a id="x"></a> `x` | `number` | [types.ts:
|
|
23
|
-
| <a id="y"></a> `y` | `number` | [types.ts:
|
|
22
|
+
| <a id="x"></a> `x` | `number` | [types.ts:54](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L54) |
|
|
23
|
+
| <a id="y"></a> `y` | `number` | [types.ts:54](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L54) |
|
|
@@ -14,12 +14,12 @@ type Vector3Input = {
|
|
|
14
14
|
};
|
|
15
15
|
```
|
|
16
16
|
|
|
17
|
-
Defined in: [types.ts:
|
|
17
|
+
Defined in: [types.ts:55](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L55)
|
|
18
18
|
|
|
19
19
|
## Properties
|
|
20
20
|
|
|
21
21
|
| Property | Type | Defined in |
|
|
22
22
|
| ------ | ------ | ------ |
|
|
23
|
-
| <a id="x"></a> `x` | `number` | [types.ts:
|
|
24
|
-
| <a id="y"></a> `y` | `number` | [types.ts:
|
|
25
|
-
| <a id="z"></a> `z` | `number` | [types.ts:
|
|
23
|
+
| <a id="x"></a> `x` | `number` | [types.ts:55](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L55) |
|
|
24
|
+
| <a id="y"></a> `y` | `number` | [types.ts:55](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L55) |
|
|
25
|
+
| <a id="z"></a> `z` | `number` | [types.ts:55](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L55) |
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
type WorldEntityView = NonNullable<ReturnType<World["getEntityById"]>>;
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
-
Defined in: [types.ts:
|
|
13
|
+
Defined in: [types.ts:128](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/020795472520adb990c488982ca8572cbf8580db/core/types.ts#L128)
|
|
14
14
|
|
|
15
15
|
Lightweight, read-only view of an entity returned by `World.getEntityById`.
|
|
16
16
|
Contains the entity id and its current component list at the moment of the
|
|
@@ -19,6 +19,7 @@ The editor can link a material slot to a **material asset** (a `.material` file
|
|
|
19
19
|
| `materials` | `THREE.Material[]` | Live three.js materials currently bound to the entity's mesh (one per submesh). |
|
|
20
20
|
| `material` | `THREE.Material \| null` | Convenience reference to `materials[0]`. `null` when no material is assigned. |
|
|
21
21
|
| `values` | `MaterialValueState[]` | Serialized authoring state (one entry per material in `materials`). Saved with the project. |
|
|
22
|
+
| `assetRefs` | `(string \| null)[]` | Editor-managed material-asset linkage, one entry per slot (parallel to `values`). A `localasset://` URL of a `.material` asset file, or `null`/absent for a local (unlinked) material. The editor materializes the asset's values into `values` and keeps them in sync when the asset is edited — rendering and the runtime read only `values` and ignore this field. Saved with the project; survives material rebinds. |
|
|
22
23
|
|
|
23
24
|
## API reference
|
|
24
25
|
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# Script Object
|
|
2
|
+
|
|
3
|
+
Component for a **script object** — a single `ScriptObject` whose THREE.js visual is built by user code and runs in the editor AND at runtime. Unlike `ScriptComponent` this holds ONE script (not an entries array). The live instance ref is non-enumerable so it never leaks into save data or undo history.
|
|
4
|
+
|
|
5
|
+
## Editor inspector
|
|
6
|
+
|
|
7
|
+
::: tip Screenshot
|
|
8
|
+
Add a screenshot of the **Script Object** component in the editor inspector here.
|
|
9
|
+
Suggested asset path: `/public/images/inspector/script-object.png`
|
|
10
|
+
:::
|
|
11
|
+
|
|
12
|
+
```md
|
|
13
|
+

|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Properties
|
|
17
|
+
|
|
18
|
+
| Property | Type | Description |
|
|
19
|
+
| --- | --- | --- |
|
|
20
|
+
| `scriptUrl` | `string \| null` | — |
|
|
21
|
+
| `className` | `string \| null` | — |
|
|
22
|
+
| `enabled` | `boolean` | — |
|
|
23
|
+
| `data` | `Record<string, unknown>` | — |
|
|
24
|
+
| `runtimeState` | `ScriptObjectRuntimeState` | — |
|
|
25
|
+
| `runtimeMessage` | `string` | — |
|
|
26
|
+
| `instance` | `unknown \| null` | Live ScriptObject instance. Non-enumerable — never enters snapshots/history. |
|
|
27
|
+
|
|
28
|
+
## API reference
|
|
29
|
+
|
|
30
|
+
- Class: [`ScriptObjectComponent`](../../api/components/classes/ScriptObjectComponent.md)
|
|
31
|
+
- Source: [`core/components/ScriptObjectComponent.ts`](https://github.com/Relu-Interactives/relu-spatial-ecs-engine/blob/main/core/components/ScriptObjectComponent.ts)
|
|
32
|
+
|
package/dist/factories/index.cjs
CHANGED
|
@@ -909,12 +909,21 @@ function normalizePhysicsState(value) {
|
|
|
909
909
|
};
|
|
910
910
|
}
|
|
911
911
|
__name(normalizePhysicsState, "normalizePhysicsState");
|
|
912
|
+
function setPhysicsLiveRef(component, key, value) {
|
|
913
|
+
Object.defineProperty(component, key, {
|
|
914
|
+
value,
|
|
915
|
+
writable: true,
|
|
916
|
+
configurable: true,
|
|
917
|
+
enumerable: false
|
|
918
|
+
});
|
|
919
|
+
}
|
|
920
|
+
__name(setPhysicsLiveRef, "setPhysicsLiveRef");
|
|
912
921
|
var _PhysicsComponent = class _PhysicsComponent extends Component {
|
|
913
922
|
constructor(values) {
|
|
914
923
|
super();
|
|
915
924
|
this.values = normalizePhysicsState(values);
|
|
916
|
-
this
|
|
917
|
-
this
|
|
925
|
+
setPhysicsLiveRef(this, "rigidBody", null);
|
|
926
|
+
setPhysicsLiveRef(this, "collider", null);
|
|
918
927
|
}
|
|
919
928
|
/**
|
|
920
929
|
* Patch rigidbody and/or collider state. Each sub-object is deep-merged
|
|
@@ -1344,6 +1353,22 @@ function getMaterialType(material) {
|
|
|
1344
1353
|
return "standard";
|
|
1345
1354
|
}
|
|
1346
1355
|
__name(getMaterialType, "getMaterialType");
|
|
1356
|
+
function textureImageSrc(texture) {
|
|
1357
|
+
const src = texture?.image?.src;
|
|
1358
|
+
return typeof src === "string" ? src : void 0;
|
|
1359
|
+
}
|
|
1360
|
+
__name(textureImageSrc, "textureImageSrc");
|
|
1361
|
+
function textureSourceUrl(texture) {
|
|
1362
|
+
if (!texture?.image) {
|
|
1363
|
+
return void 0;
|
|
1364
|
+
}
|
|
1365
|
+
const currentSrc = texture.source?.data?.currentSrc;
|
|
1366
|
+
if (typeof currentSrc === "string" && currentSrc) {
|
|
1367
|
+
return currentSrc;
|
|
1368
|
+
}
|
|
1369
|
+
return textureImageSrc(texture);
|
|
1370
|
+
}
|
|
1371
|
+
__name(textureSourceUrl, "textureSourceUrl");
|
|
1347
1372
|
function createMaterialValue(material) {
|
|
1348
1373
|
const materialRecord = material;
|
|
1349
1374
|
const normalScale = materialRecord.normalScale;
|
|
@@ -1363,17 +1388,33 @@ function createMaterialValue(material) {
|
|
|
1363
1388
|
depthWrite: materialRecord.depthWrite !== false,
|
|
1364
1389
|
wireframe: Boolean(materialRecord.wireframe),
|
|
1365
1390
|
transparent: Boolean(materialRecord.transparent),
|
|
1366
|
-
textureMap: map
|
|
1367
|
-
alphaTextureMap:
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1391
|
+
textureMap: textureSourceUrl(map),
|
|
1392
|
+
alphaTextureMap: textureImageSrc(
|
|
1393
|
+
materialRecord.alphaMap
|
|
1394
|
+
),
|
|
1395
|
+
normalMap: textureImageSrc(
|
|
1396
|
+
materialRecord.normalMap
|
|
1397
|
+
),
|
|
1398
|
+
roughnessMap: textureImageSrc(
|
|
1399
|
+
materialRecord.roughnessMap
|
|
1400
|
+
),
|
|
1401
|
+
metalnessMap: textureImageSrc(
|
|
1402
|
+
materialRecord.metalnessMap
|
|
1403
|
+
),
|
|
1404
|
+
aoMap: textureImageSrc(materialRecord.aoMap),
|
|
1405
|
+
emissiveMap: textureImageSrc(
|
|
1406
|
+
materialRecord.emissiveMap
|
|
1407
|
+
),
|
|
1408
|
+
bumpMap: textureImageSrc(
|
|
1409
|
+
materialRecord.bumpMap
|
|
1410
|
+
),
|
|
1411
|
+
displacementMap: textureImageSrc(
|
|
1412
|
+
materialRecord.displacementMap
|
|
1413
|
+
),
|
|
1414
|
+
lightMap: textureImageSrc(
|
|
1415
|
+
materialRecord.lightMap
|
|
1416
|
+
),
|
|
1417
|
+
envMap: textureImageSrc(materialRecord.envMap),
|
|
1377
1418
|
textureFiltering: map?.magFilter === THREE29__namespace.NearestFilter ? "sharp" : "smooth",
|
|
1378
1419
|
useMipmaps: map?.generateMipmaps !== false
|
|
1379
1420
|
};
|