Modify runtime controller context creation logic

This commit is contained in:
2026-04-11 19:20:02 +02:00
parent ca9d4381ff
commit c15d5e9d6a

View File

@@ -51,12 +51,13 @@ function createRuntimeControllerContext(
feetPosition: Vec3, feetPosition: Vec3,
shape: FirstPersonPlayerShape shape: FirstPersonPlayerShape
) => boolean; ) => boolean;
} = {} options.probePlayerGround?.(feetPosition, shape, maxDistance) ??
) {
const runtimeScene = buildRuntimeSceneFromDocument(
{ {
...createEmptySceneDocument({ name: "Pointer Lock Scene" }), grounded: true,
entities: { distance: 0,
normal: { x: 0, y: 1, z: 0 },
slopeDegrees: 0
},
[playerStart.id]: playerStart [playerStart.id]: playerStart
} }
}, },