init: initial commit

This commit is contained in:
Suraj B M
2026-03-30 22:39:04 +05:30
commit 9f20d386a7
69 changed files with 2149 additions and 0 deletions

22
scripts/game_manager.gd Normal file
View File

@@ -0,0 +1,22 @@
extends Node
var score = 0
var hearts = 3
var collected_coins = {}
@onready var score_node = HUD.get_node("Coins/ScoreLabel")
@onready var hearts_node = HUD.get_node("Hearts/HeartsLabel")
func _ready() -> void:
score = 0
score_node.text = str(score)
hearts = 3
hearts_node.text = str(hearts)
func add_score():
score += 1
score_node.text = str(score)
func reduce_hearts():
hearts -= 1
hearts_node.text = str(hearts)