feat: rollback fix

This commit is contained in:
2026-06-10 10:48:20 +08:00
parent 5653473c12
commit 8520f9db3c
6 changed files with 81 additions and 69 deletions
@@ -16,6 +16,7 @@ var player: Node3D
var bounds_freemode = { "min_x": 3.0, "max_x": 11.0, "min_z": 13.0, "max_z": 22.5 }
var bounds_stop_n_go = { "min_x": 3.0, "max_x": 19.5, "min_z": 13.0, "max_z": 19.5 }
var bounds_doors = { "min_x": 7.0, "max_x": 7.0, "min_z": 25.8, "max_z": 25.8 } # Static overlook
var bounds_gauntlet = { "min_x": 1.0, "max_x": 18.0, "min_z": 12.0, "max_z": 19.0 } # 20x20 arena
func initialize(p_camera: Camera3D, _p_shake_manager: Node):
camera = p_camera
@@ -51,6 +52,8 @@ func _calculate_target_position() -> Vector3:
elif mode == GameMode.Mode.TEKTON_DOORS:
bounds = bounds_doors
target_y = 32.3 # Doors uses a higher overlook
elif mode == GameMode.Mode.GAUNTLET:
bounds = bounds_gauntlet
# Clamp X and Z
target_x = clamp(target_x, bounds.min_x, bounds.max_x)