ArcherTower and Arrows

This commit is contained in:
2025-03-17 11:30:18 +01:00
parent d701893663
commit 9d853dd4f3
14 changed files with 253 additions and 2 deletions

View File

@ -8,7 +8,7 @@ const COBOLD = preload("res://Game/Mobs/cobold.tscn")
const enemies = [FORKMAN, COBOLD, ORK]
var lives = 2
var lives = 20
func _ready() -> void:
get_node("SidePanel").Update_Lives(lives)
@ -27,7 +27,7 @@ func spawnMonster():
func decrease_life(damage) -> void:
lives -= damage
get_node("SidePanel").Update_Lives(lives)
if lives == 0:
if lives <= 0:
game_over()
func game_over()-> void: