number keys for weapons; charger enemy is invulnerable

This commit is contained in:
Michael Campbell 2026-03-19 01:44:53 -04:00
parent 1d1d201520
commit ae7d507a4c
5 changed files with 27 additions and 9 deletions

View file

@ -137,8 +137,12 @@ func _process(delta: float) -> void:
damage_clock -= delta
if Input.is_action_just_pressed("swap_weapons"):
gun_index += 1
if Input.is_action_just_pressed("sharpshooter"):
gun_index = 0
if Input.is_action_just_pressed("minigun"):
gun_index = 1
if Input.is_action_just_pressed("mortar"):
gun_index = 2
func damage(damager: Node3D) -> void:
if health <= 0: return