This commit is contained in:
Nikolai Fesenko
2025-08-29 00:05:43 +02:00
parent 4e810f8fc0
commit 9c2d5d34e5
7 changed files with 64 additions and 13 deletions

View File

@@ -29,6 +29,7 @@ func _process(delta: float) -> void:
#cylinder.rotation_degrees = Vector3(30 + current_round*60,90,90)
func load_bullet(bullet_object: Node3D):
loaded_bullets[current_round] = bullet_object
bullet_object.is_loaded = true
bullet_object.destination_reached.connect(on_bullet_reached)
bullet_object.moveTo(to_global(bullet_target_pos))
bullet_object.rotate_x(deg_to_rad(-90))
@@ -39,7 +40,10 @@ func load_bullet(bullet_object: Node3D):
func on_load_anim_end():
is_cylinder_out = false
GameManager.end_turn()
if is_player_revolver:
GameManager.end_player_turn()
else:
GameManager.end_enemy_turn()
timer.timeout.disconnect(on_load_anim_end)
func on_bullet_reached():