From 99c56fb46f25aeb49f5c622efef3aed9947d5c50 Mon Sep 17 00:00:00 2001 From: Luna Brovchuk Date: Sun, 1 Oct 2023 20:01:53 +0200 Subject: [PATCH] Fix Sorting In-Game UI --- src/models/enemies/rat/Rat.tscn | 2 +- src/scripts/global.gd | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/models/enemies/rat/Rat.tscn b/src/models/enemies/rat/Rat.tscn index 9b134d0..34a0e7a 100644 --- a/src/models/enemies/rat/Rat.tscn +++ b/src/models/enemies/rat/Rat.tscn @@ -13,7 +13,7 @@ script = ExtResource( 2 ) use_parent_material = true frames = ExtResource( 1 ) animation = "idle" -frame = 3 +frame = 1 playing = true centered = false diff --git a/src/scripts/global.gd b/src/scripts/global.gd index 6e92539..f7e617a 100644 --- a/src/scripts/global.gd +++ b/src/scripts/global.gd @@ -17,6 +17,6 @@ func return_to_menu(): func add_health(amount): health = clamp(health + amount, 0, 3) - get_tree().get_root().get_node("Game/UIWrapper/UI/Health/HealthSprite").frame = health + get_tree().get_root().get_node("Game/UIWrapper/UI/Left/Health/HealthSprite").frame = health if health == 0: return_to_menu() # TODO endgame