Skip to content

Commit

Permalink
Fixes underbarrel extinguishers (#4102)
Browse files Browse the repository at this point in the history
# About the pull request
Closes #4036
You can now refill underbarrel extinguishers at watertanks and such when
they are selected.


# Testing Photographs and Procedure
<details>
<summary>Screenshots & Videos</summary>


![image](https://github.com/cmss13-devs/cmss13/assets/41448081/b9d57670-0532-46d8-8c24-baae3e099618)

</details>


# Changelog
:cl:
fix: Underbarrel extinguishers can now be refilled.
/:cl:

Co-authored-by: John Doe <[email protected]>
  • Loading branch information
Zonespace27 and johndoe2013 authored Aug 4, 2023
1 parent aa0c3a6 commit bbeab9d
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions code/modules/projectiles/gun.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1218,6 +1218,16 @@ and you're good to go.

#define EXECUTION_CHECK (attacked_mob.stat == UNCONSCIOUS || attacked_mob.is_mob_restrained()) && ((user.a_intent == INTENT_GRAB)||(user.a_intent == INTENT_DISARM))

/obj/item/weapon/gun/afterattack(atom/target, mob/user, proximity_flag, click_parameters)
if(!proximity_flag)
return FALSE

if(active_attachable && (active_attachable.flags_attach_features & ATTACH_MELEE))
active_attachable.last_fired = world.time
active_attachable.fire_attachment(target, src, user)
return TRUE


/obj/item/weapon/gun/attack(mob/living/attacked_mob, mob/living/user)
if(active_attachable && (active_attachable.flags_attach_features & ATTACH_MELEE)) //this is expected to do something in melee.
active_attachable.last_fired = world.time
Expand Down

0 comments on commit bbeab9d

Please sign in to comment.