This commit is contained in:
bee
2026-07-07 10:01:56 +02:00
parent 2e28afebce
commit e946b43db7
13 changed files with 140 additions and 63 deletions
+3 -3
View File
@@ -25,6 +25,9 @@ func _physics_process(delta: float) -> void:
throttle = move_toward(throttle, desired_throttle, throttle_response * delta)
if submerged_ratio <= 0.0:
return # airborne: no thrust, no rudder, no keel
# boat's forward direction, flattened onto the water plane
var forward := -global_basis.z
forward.y = 0.0
@@ -40,9 +43,6 @@ func _physics_process(delta: float) -> void:
var rudder_bite := clampf(forward_speed / 3.0, -1.0, 1.0)
apply_torque(Vector3.UP * steer_input * rudder_strength * rudder_bite * mass * submerged_ratio)
if submerged_ratio <= 0.0:
return # airborne: no thrust, no rudder, no keelffffff
# --- keel: kill sideways sliding ---
var right := global_basis.x
right.y = 0.0