@relu-interactives/spatial-ecs 0.3.1 → 0.3.2
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/{chunk-PCOZLCXS.js → chunk-JWTRFJBL.js} +12 -4
- package/dist/chunk-JWTRFJBL.js.map +1 -0
- package/dist/{chunk-VXUVNC7S.js → chunk-SALBG747.js} +127 -3
- package/dist/chunk-SALBG747.js.map +1 -0
- package/dist/factories/index.cjs +10 -2
- package/dist/factories/index.cjs.map +1 -1
- package/dist/factories/index.js +1 -1
- package/dist/{index-YYypJaVw.d.cts → index-Bc0YCz1A.d.cts} +27 -1
- package/dist/{index-D84o_UA6.d.ts → index-CRmfSYdj.d.ts} +27 -1
- package/dist/index.cjs +138 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +6 -4
- package/dist/index.js.map +1 -1
- package/dist/systems/index.cjs +126 -0
- package/dist/systems/index.cjs.map +1 -1
- package/dist/systems/index.d.cts +1 -1
- package/dist/systems/index.d.ts +1 -1
- package/dist/systems/index.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-PCOZLCXS.js.map +0 -1
- package/dist/chunk-VXUVNC7S.js.map +0 -1
package/dist/factories/index.cjs
CHANGED
|
@@ -3263,11 +3263,19 @@ function createTeleportArea({
|
|
|
3263
3263
|
depthWrite: false
|
|
3264
3264
|
});
|
|
3265
3265
|
const object = new THREE31__namespace.Mesh(geometry, material);
|
|
3266
|
-
object.rotation.x = -Math.PI / 2;
|
|
3267
3266
|
const entityId = createBaseEntity(world, object, {
|
|
3268
3267
|
label: payload.name ?? "Teleport Area",
|
|
3269
3268
|
entityType: "teleportArea",
|
|
3270
|
-
|
|
3269
|
+
// The flat-on-the-ground rotation must live in the ECS TRANSFORM, not on
|
|
3270
|
+
// the Object3D: createBaseEntity applies the transform over the object, and
|
|
3271
|
+
// TransformSyncSystem re-applies it every frame — so a rotation set
|
|
3272
|
+
// directly on the mesh is overwritten immediately and the area stands up
|
|
3273
|
+
// like a wall. Same convention as the `plane` primitive.
|
|
3274
|
+
transformInput: {
|
|
3275
|
+
position: payload.transform?.position,
|
|
3276
|
+
rotation: payload.transform?.rotation ?? { x: -Math.PI / 2, y: 0, z: 0 },
|
|
3277
|
+
scale: payload.transform?.scale
|
|
3278
|
+
}
|
|
3271
3279
|
});
|
|
3272
3280
|
world.addComponent(
|
|
3273
3281
|
entityId,
|