Nerfs circuit pneumatic cannons and guns with extra sanity checks.

This commit is contained in:
Ghommie
2019-12-04 01:07:36 +01:00
parent 71a5d12c44
commit 91ffa11bc9
4 changed files with 43 additions and 25 deletions
+5 -4
View File
@@ -198,8 +198,13 @@
/obj/item/gun/can_trigger_gun(mob/living/user)
. = ..()
if(!.)
return
if(!handle_pins(user))
return FALSE
if(HAS_TRAIT(user, TRAIT_PACIFISM) && chambered?.harmful) // If the user has the pacifist trait, then they won't be able to fire [src] if the round chambered inside of [src] is lethal.
to_chat(user, "<span class='notice'> [src] is lethally chambered! You don't want to risk harming anyone...</span>")
return FALSE
/obj/item/gun/proc/handle_pins(mob/living/user)
if(pin)
@@ -275,10 +280,6 @@
addtimer(CALLBACK(src, .proc/process_burst, user, target, message, params, zone_override, sprd, randomized_gun_spread, randomized_bonus_spread, rand_spr, i), fire_delay * (i - 1))
else
if(chambered)
if(HAS_TRAIT(user, TRAIT_PACIFISM)) // If the user has the pacifist trait, then they won't be able to fire [src] if the round chambered inside of [src] is lethal.
if(chambered.harmful) // Is the bullet chambered harmful?
to_chat(user, "<span class='notice'> [src] is lethally chambered! You don't want to risk harming anyone...</span>")
return
sprd = round((rand() - 0.5) * DUALWIELD_PENALTY_EXTRA_MULTIPLIER * (randomized_gun_spread + randomized_bonus_spread))
if(!chambered.fire_casing(target, user, params, , suppressed, zone_override, sprd, src))
shoot_with_empty_chamber(user)