This commit is contained in:
Nicholas Butzke
2026-08-09 01:31:44 -04:00
parent 922983429e
commit 9358746582
43 changed files with 4324 additions and 481 deletions
+23 -1
View File
@@ -19,6 +19,7 @@ const FOOT_SOCKETS := [
var _flames: Array[Node3D] = []
var _burst_left := 0.0
var _dash_active := false
var _wall_glide_active := false
var _dash_tail := 0.0
var _render_enabled := true
var _exhaust_direction := Vector3.DOWN
@@ -110,10 +111,29 @@ func set_dash(active: bool, movement_local: Vector2) -> void:
_exhaust_direction = (-move.normalized() + Vector3.DOWN * 0.20).normalized()
func set_wall_glide(active: bool, movement_local: Vector2) -> void:
_wall_glide_active = active
if not active:
return
var move := Vector3(movement_local.x, 0.0, -movement_local.y)
if move.length_squared() < 0.01:
move = Vector3.FORWARD
# Continuous thrust opposes travel with only a slight downward cant. This
# reads as vector jets carrying the pilot along the wall, not a jump burst.
_exhaust_direction = (-move.normalized() + Vector3.DOWN * 0.08).normalized()
func get_flame_count() -> int:
return _flames.size()
func get_flame_world_positions() -> Array[Vector3]:
var result: Array[Vector3] = []
for flame in _flames:
result.append(flame.global_position)
return result
func get_exhaust_direction() -> Vector3:
return _exhaust_direction
@@ -124,7 +144,7 @@ func _process(delta: float) -> void:
_burst_left = maxf(0.0, _burst_left - delta)
_dash_tail = maxf(0.0, _dash_tail - delta)
var dash_visible := _dash_active or _dash_tail > 0.0
var active := dash_visible or _burst_left > 0.0
var active := dash_visible or _burst_left > 0.0 or _wall_glide_active
visible = _render_enabled and active
if not visible:
return
@@ -135,6 +155,8 @@ func _process(delta: float) -> void:
_exhaust_direction = Vector3(0.0, -1.0, 0.16).normalized()
var pulse := 0.90 + sin(_time * 54.0) * 0.08 + sin(_time * 31.0) * 0.04
if _wall_glide_active:
pulse *= 1.32
if _burst_left > 0.0 and not _dash_active:
pulse *= clampf(_burst_left / 0.08, 0.15, 1.0)
for i in _flames.size():