#22 développement du pourcentage de contamination

This commit is contained in:
2025-08-19 09:44:59 +02:00
parent f5be43767a
commit b0efeff809
15 changed files with 101 additions and 97 deletions

View File

@@ -7,7 +7,7 @@ signal day_pass_proceed
signal day_pass_finished
func _on_player_updated(player:Player):
$MarginContainer/PlayerInfo.player_update(player)
%EnergyCount.text = str(player.energy)
%AvailableActions/GetItem.visible = player.closest_interactable is ItemObject and player.inventory.lenght() == 0
%AvailableActions/SwapItem.visible = player.closest_interactable is ItemObject and player.inventory.lenght() > 0
@@ -23,9 +23,6 @@ func _on_player_updated(player:Player):
%ItemName.text = item.name
%ItemDesc.text = item.description
func _on_planet_planet_stats_updated(day:int):
$MarginContainer/DayCount.text = "Day " + str(day)
func _on_day_pass_pressed():
day_pass_pressed.emit()
$AnimationPlayer.play("recharge_fade_in")
@@ -37,3 +34,7 @@ func _on_day_pass_pressed():
func _on_game_action_button_down():
game_click.emit()
func _on_planet_updated(planet:Planet):
$MarginContainer/DayCount.text = "Day " + str(planet.day)
%DecontaminationCoverage.text = str(roundi(planet.decontamination_coverage * 100)) + "%"