hold right+left, it charges ahead
This commit is contained in:
+5
-1
@@ -12,6 +12,9 @@ var _tilt_x: float = 0.0
|
||||
var _tilt_z: float = 0.0
|
||||
var _aerial_pitch: float = 0.0
|
||||
|
||||
var charge_pitch_target: float = 0.0
|
||||
var _charge_pitch_curr: float = 0.0
|
||||
|
||||
# Tail — Verlet chain simulation
|
||||
const TAIL_BONES: Array = [
|
||||
&"tail_1", &"tail_2", &"tail_3", &"tail_4",
|
||||
@@ -111,7 +114,8 @@ func _wobble_body(delta: float) -> void:
|
||||
target_pitch = clampf(-atan2(vel.y, flat_spd) * DP.f("aerial_pitch_scale"), -1.4, 1.4)
|
||||
_aerial_pitch = lerpf(_aerial_pitch, target_pitch, delta * DP.f("aerial_pitch_speed"))
|
||||
|
||||
_bull.rotation.x = _tilt_x + _aerial_pitch
|
||||
_charge_pitch_curr = lerpf(_charge_pitch_curr, charge_pitch_target, delta * DP.f("charge_head_speed"))
|
||||
_bull.rotation.x = _tilt_x + _aerial_pitch + _charge_pitch_curr
|
||||
_bull.rotation.z = _tilt_z
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user