rock respawn flow, fix flying spawn

This commit is contained in:
2026-04-22 18:49:13 +03:00
parent 6a5c3a0def
commit 66b8120eb7
2 changed files with 53 additions and 5 deletions
+3
View File
@@ -1,5 +1,7 @@
extends CharacterBody3D
signal destroyed
enum State { IDLE, FLYING }
const AIR_FRICTION := 0.84
@@ -100,6 +102,7 @@ func _die() -> void:
dead = true
state = State.IDLE
set_physics_process(false)
emit_signal("destroyed")
var tw := create_tween()
tw.tween_property(self, "scale", Vector3(1.6, 0.1, 1.6), 0.12)
tw.tween_property(self, "scale", Vector3(0.0, 0.0, 0.0), 0.1)