Skip to content

Commit

Permalink
Fixedwhen the UI shows up for the player. Previously it was shown whe…
Browse files Browse the repository at this point in the history
…n the players turn had ended for a brief second.
  • Loading branch information
ra314 committed Apr 13, 2022
1 parent b734914 commit 2efc568
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Scripts/Levels/Level Main.gd
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ func _ready():
grid.connect("swap_start", self, "before_process")
grid.connect("swap_end", self, "after_process")
grid.connect("shuffle_tiles_end", self, "after_process")
grid.connect("shuffle_tiles_end", self, "update_curr_player_ui_and_show_berries")
grid.connect("collect_mana_from_grid", self, "distribute_mana")
grid.connect("extra_move", self, "add_extra_move")
grid.ready()
Expand All @@ -115,6 +116,9 @@ func _ready():

start_turn()

func update_curr_player_ui_and_show_berries():
curr_player.update_ui(true)

func create_organism_ability_notification(organism, duration, alignment):
_root.create_notification(organism.ability_description, duration, alignment)

Expand All @@ -138,7 +142,6 @@ func distribute_mana(mana_array):
for organism in curr_player.organisms:
var mana_to_give = mana_array[organism.mana_enum]
mana_array[organism.mana_enum] -= organism.change_mana(mana_to_give)
curr_player.update_ui(true)

signal turn_starting
func start_turn():
Expand Down

0 comments on commit 2efc568

Please sign in to comment.