Fix Godot Vector3.Up and stiffen terrain suspension for 34 m/s dune climbs

This commit is contained in:
Meta Vens 2026-12-04 15:17:07 +01:00
commit ade15c3325
2 changed files with 5 additions and 5 deletions

View file

@ -311,7 +311,7 @@ public partial class Main : Node3D
_cameraSmoothedAnchor = _cameraSmoothedAnchor.Lerp(targetAnchor, blend);
var camFwdHoriz = new Vector3(MathF.Sin(_cameraYaw), 0f, MathF.Cos(_cameraYaw));
var lookDir = (camFwdHoriz * MathF.Cos(_cameraPitch) - Vector3.UnitY * MathF.Sin(_cameraPitch)).Normalized();
var lookDir = (camFwdHoriz * MathF.Cos(_cameraPitch) - Vector3.Up * MathF.Sin(_cameraPitch)).Normalized();
// Pull camera forward along arm if terrain or static cover blocks the shoulder-to-camera ray
float effectiveBack = backDist;