This commit is contained in:
2025-10-28 02:22:59 +01:00
parent bfd653c136
commit f6fe381551
17 changed files with 647 additions and 157 deletions

View File

@@ -16,15 +16,16 @@ func transition_end() -> void:
func run_event(event: Events, player_postion: Vector2 = Vector2.ZERO):
current_event = event
transition_start()
if player != null && player_postion != Vector2.ZERO:
player.position = player_postion
match event:
Events.PUMPKIN_CARVE:
player_free = false
get_tree().change_scene_to_file("uid://ccfdsdgaon63m") # scenes/levels/home.tscn
transition_end()
transition_scene_file("uid://ccfdsdgaon63m") # scenes/levels/home.tscn
await get_tree().scene_changed
await get_tree().create_timer(2).timeout
var pumpkin_carve: Control = preload("res://scenes/menus/pumpkin_carve.tscn").instantiate()
add_child(pumpkin_carve)
func transition_scene_file(scene: String) -> void:
if !animation_player.is_playing():