mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-11-24 06:34:18 +01:00
feat: move poses
This commit is contained in:
1 parent
103c1b4338
commit
480fda34ce
4 files changed
+120
-36
No files matched your search
@@ -71,7 +71,29 @@ export function TankSandbox({ duel }: TankSandboxProps) {
|
||||
draft.model.physical.pitch = pitch;
|
||||
draft.model.physical.yaw = yaw;
|
||||
});
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
case Pose.FaceHug: {
|
||||
mutateTankopedia((draft) => {
|
||||
const [pitch, yaw] = applyPitchYawLimits(
|
||||
0,
|
||||
0,
|
||||
gunModelDefinition.pitch,
|
||||
turretModelDefinition.yaw,
|
||||
);
|
||||
|
||||
modelTransformEvent.emit({ pitch, yaw });
|
||||
draft.model.physical.pitch = pitch;
|
||||
draft.model.physical.yaw = yaw;
|
||||
});
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
case Pose.Default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -134,7 +156,7 @@ export function TankSandbox({ duel }: TankSandboxProps) {
|
||||
<Canvas
|
||||
shadows
|
||||
ref={canvas}
|
||||
camera={{ fov: 20 }}
|
||||
camera={{ fov: 25 }}
|
||||
onPointerDown={handlePointerDown}
|
||||
>
|
||||
<Controls duel={duel} />
|
||||
|
||||
Reference in new issue
Block a user