Animation des cellules entre les jours corrigées

This commit is contained in:
Altaezio
2026-07-02 10:41:04 +02:00
parent 281f42d90c
commit 53e86be2ce
3 changed files with 15 additions and 12 deletions

View File

@@ -13,7 +13,7 @@ var max_energy := 0
func update(
_energy : int,
_max_energy : int,
_with_animation := true,
with_animation := true,
):
var changed = (energy != _energy or max_energy != _max_energy)
if changed:
@@ -23,7 +23,7 @@ func update(
# if with_animation:
# %EnergyAnimationPlayer.bounce()
%EnergyInfo3d.energy = energy
%EnergyInfo3d.set_energy(energy, with_animation)
%EnergyInfo3d.max_energy = max_energy
%EnergyCount.text = energy_count_text
%EnergyCount.modulate = Color.WHITE if energy > 0 else Color.RED