modification de l'interface pour mieux modifier la vie affichée

This commit is contained in:
E213872U 2025-01-25 01:03:45 +01:00
parent af73f06da0
commit 303f40c3cc
10 changed files with 281 additions and 8 deletions

View file

@ -134,12 +134,6 @@ texture = ExtResource("4_6a3f6")
[node name="Slime" parent="." groups=["Enemies"] instance=ExtResource("3_04ip2")]
position = Vector2(-448, 205)
[node name="Interface" parent="." instance=ExtResource("8_5s7tf")]
offset_left = -640.0
offset_top = -360.0
offset_right = -640.0
offset_bottom = -360.0
[node name="Menu_parametres" parent="." instance=ExtResource("6_6ubhx")]
process_mode = 3
visible = false
@ -148,4 +142,10 @@ offset_top = -360.0
offset_right = 640.0
offset_bottom = 360.0
[node name="Interface" parent="." instance=ExtResource("8_5s7tf")]
offset_left = -640.0
offset_top = -360.0
offset_right = -640.0
offset_bottom = -360.0
[connection signal="finished" from="Musique" to="." method="_on_audio_stream_player_finished"]

View file

@ -21,9 +21,10 @@ func _ready() -> void:
func _process(delta: float) -> void:
pass
func healing(pv : int) -> void :
for i in range(life , life+pv+1):
func set_life(pv : int) -> void :
for i in range(life, pv):
update_life(i)
update_life(pv)
func update_life (pv : int) -> void :
match pv :