Update engine.ts

This commit is contained in:
syuilo
2026-02-10 11:43:16 +09:00
parent cb1d9c38df
commit 4ee5c73bca

View File

@@ -633,6 +633,7 @@ export class RoomEngine {
const soMesh = this.objectMeshs.get(soid)!;
soMesh.parent = null;
soMesh.position = soMesh.position.add(mesh.position);
soMesh.rotation = soMesh.rotation.add(mesh.rotation);
removeStickyParentRecursively(soMesh);
}
};
@@ -666,6 +667,7 @@ export class RoomEngine {
setStickyParentRecursively(soMesh);
soMesh.parent = mesh;
soMesh.position = soMesh.position.subtract(mesh.position);
soMesh.rotation = soMesh.rotation.subtract(mesh.rotation);
}
};
setStickyParentRecursively(highlightedObject);