Skip to content

Commit

Permalink
two tweaks to fix bugs with null default_ammo_types
Browse files Browse the repository at this point in the history
  • Loading branch information
FalloutFalcon committed Sep 25, 2024
1 parent 407153a commit 836139b
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 1 addition & 1 deletion code/modules/projectiles/guns/ballistic.dm
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
bolt_locked = TRUE
update_appearance()
return
if (!magazine)
if (!magazine && default_ammo_type)
magazine = new default_ammo_type(src)
if (!default_ammo_type)
get_ammo_list (drop_all = TRUE)
Expand Down
2 changes: 0 additions & 2 deletions code/modules/projectiles/guns/energy.dm
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,6 @@
. = ..()
if(default_ammo_type)
cell = new default_ammo_type(src)
else
cell = new(src)
if(dead_cell)
cell.use(cell.maxcharge)
update_ammo_types()
Expand Down

0 comments on commit 836139b

Please sign in to comment.