starting to fix guns under new script workflow
This commit is contained in:
@@ -24,7 +24,8 @@ func picked_up():
|
||||
|
||||
if !gun_already_held:
|
||||
var spawn_gun = gun_resource.instantiate()
|
||||
level_control.player.add_ammo(true,spawn_gun.weapon_info.gun_name,spawn_gun.weapon_info.bullet_info.ammo_type,spawn_gun.weapon_info.max_ammo,spawn_gun.weapon_info.start_mags)
|
||||
if spawn_gun.weapon_info.weapon_type == 0:
|
||||
level_control.player.add_ammo(true,spawn_gun.weapon_info.gun_name,spawn_gun.weapon_info.bullet.ammo_type,spawn_gun.weapon_info.max_ammo,spawn_gun.weapon_info.start_mags)
|
||||
GameGlobals.held_guns.append(gun_resource)
|
||||
var instance_gun = gun_resource.instantiate()
|
||||
var weapon_id = GameGlobals.held_guns.size() - 1
|
||||
|
||||
Reference in New Issue
Block a user