feat: add dust2 level builder, player movement controller, and UI menu components

This commit is contained in:
DottsGit
2026-06-06 15:17:54 -04:00
parent 31336fe870
commit cd034d1aea
5 changed files with 130 additions and 64 deletions
+3
View File
@@ -311,6 +311,7 @@ func _ensure_machine() -> MovementStateMachine:
return null
func _physics_process(_delta: float) -> void:
if not is_multiplayer_authority(): return
var speed = velocity.length()
var wind_factor = clampf((speed - 10.0) / 25.0, 0.0, 1.0)
# Decibel scale is non-linear, so lerping from -80 means it stays inaudible for a long time.
@@ -401,6 +402,7 @@ func _on_movement_event(ev: String, data: Dictionary) -> void:
grapple_latch_player.play()
func _process(delta: float) -> void:
if not is_multiplayer_authority(): return
if is_dead:
# Continuously follow the ragdoll torso
if is_instance_valid(ragdoll_instance) and is_instance_valid(camera):
@@ -632,6 +634,7 @@ func die(impulse: Vector3 = Vector3.ZERO) -> void:
set_process_input(true)
func _input(event: InputEvent) -> void:
if not is_multiplayer_authority(): return
if is_dead and death_screen and death_screen.visible:
if event is InputEventKey or event is InputEventMouseButton or event is InputEventJoypadButton:
if event.is_pressed() and not event.is_echo():