feat: added the knife

This commit is contained in:
DottsGit
2026-06-06 02:22:27 -04:00
parent 90876611f4
commit 18b8b3ee99
6 changed files with 211 additions and 2 deletions
+8 -1
View File
@@ -62,6 +62,11 @@ var weapon_db = {
"name": "Mortar",
"category": "special",
"script": "res://weapons/mortar.gd"
},
"knife": {
"name": "Knife",
"category": "melee",
"script": "res://weapons/knife.gd"
}
}
@@ -80,7 +85,8 @@ func _ensure_default_loadouts() -> void:
"name": "Loadout " + str(i + 1),
"primary_1": "double_barrel_shotgun",
"primary_2": "none",
"special": "none"
"special": "none",
"melee": "knife"
})
func get_active_loadout() -> Dictionary:
@@ -123,3 +129,4 @@ func load_loadouts() -> void:
if sl.has("primary_1"): loadouts[i]["primary_1"] = sl["primary_1"]
if sl.has("primary_2"): loadouts[i]["primary_2"] = sl["primary_2"]
if sl.has("special"): loadouts[i]["special"] = sl["special"]
if sl.has("melee"): loadouts[i]["melee"] = sl["melee"]