fixed hud, moved weapon and ammo penalties to gamemode

This commit is contained in:
derek
2025-03-18 10:16:09 -05:00
parent d17bc56ca2
commit 891ae8a7f2
10 changed files with 79 additions and 42 deletions

View File

@@ -43,23 +43,3 @@ func deposit_money():
func _process(delta: float) -> void:
pass
#print("current level : ",get_tree().current_scene.scene_file_path)
func money_penalty():
var level_control = get_tree().current_scene
#Do money penalty
money = money * level_control.gamemode.money_lost_multiplier
deposited_money = money
func weapon_penalty():
var level_control = get_tree().current_scene
GameGlobals.ammo_reserve = {}
match level_control.gamemode.weapon_penalty:
0: #Drop All
GameGlobals.held_guns = []
1: #Drop Percentage
var weapons_lost = GameGlobals.held_guns.size() * level_control.gamemode.weapon_drop_percentage
for weapon in weapons_lost:
GameGlobals.held_guns.erase(GameGlobals.held_guns.pick_random())
2: #Do Nothing
pass