[MIRROR] harmful var for guns (#5879)

* harmful var for guns (#36265)

* harmful var for guns

support for pacifism to use non-harmful guns

* fixes bad spacing

oops

* harmful var for guns
This commit is contained in:
CitadelStationBot
2018-03-10 07:57:57 -06:00
committed by Poojawa
parent 4f4d486244
commit aa7b9f192f
8 changed files with 24 additions and 2 deletions
+6 -1
View File
@@ -851,11 +851,16 @@
return FALSE
return TRUE
/mob/living/proc/can_use_guns(obj/item/G)
/mob/living/proc/can_use_guns(obj/item/G)//actually used for more than guns!
if(G.trigger_guard != TRIGGER_GUARD_ALLOW_ALL && !IsAdvancedToolUser())
to_chat(src, "<span class='warning'>You don't have the dexterity to do this!</span>")
return FALSE
var/obj/item/gun/shooty
if(istype(G, /obj/item/gun))
shooty = G
if(has_trait(TRAIT_PACIFISM))
if(shooty && !shooty.harmful)
return TRUE
to_chat(src, "<span class='notice'>You don't want to risk harming anyone!</span>")
return FALSE
return TRUE