diff --git a/code/modules/mob/living/carbon/human/inventory.dm b/code/modules/mob/living/carbon/human/inventory.dm
index c5ed01fd688..dbd6a391bad 100644
--- a/code/modules/mob/living/carbon/human/inventory.dm
+++ b/code/modules/mob/living/carbon/human/inventory.dm
@@ -431,159 +431,161 @@
if ((!( (istype(target.wear_mask, /obj/item/clothing/mask) && istype(target.back, /obj/item/weapon/tank) && !( target.internal )) ) && !( target.internal )))
del(src)
- var/list/L = list( "syringe", "pill", "drink", "dnainjector", "fuel")
- if ((item && !( L.Find(place) )))
- if(isrobot(source) && place != "handcuff")
- del(src)
- for(var/mob/O in viewers(target, null))
- O.show_message("\red [source] is trying to put \a [item] on [target]", 1)
- else
- var/message=null
- switch(place)
- if("syringe")
- message = "\red [source] is trying to inject [target]!"
- if("pill")
- message = "\red [source] is trying to force [target] to swallow [item]!"
- if("drink")
- message = "\red [source] is trying to force [target] to swallow a gulp of [item]!"
- if("dnainjector")
- message = "\red [source] is trying to inject [target] with the [item]!"
- if("mask")
- target.attack_log += text("\[[time_stamp()]\] Had their mask removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) mask")
- if(target.wear_mask && !target.wear_mask.canremove)
- message = "\red [source] fails to take off \a [target.wear_mask] from [target]'s head!"
- return
- else
- message = "\red [source] is trying to take off \a [target.wear_mask] from [target]'s head!"
- if("l_hand")
- target.attack_log += text("\[[time_stamp()]\] Has had their left hand item ([target.l_hand]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) left hand item ([target.l_hand])")
- message = "\red [source] is trying to take off \a [target.l_hand] from [target]'s left hand!"
- if("r_hand")
- target.attack_log += text("\[[time_stamp()]\] Has had their right hand item ([target.r_hand]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) right hand item ([target.r_hand])")
- message = "\red [source] is trying to take off \a [target.r_hand] from [target]'s right hand!"
- if("gloves")
- target.attack_log += text("\[[time_stamp()]\] Has had their gloves ([target.gloves]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) gloves ([target.gloves])")
- if(target.gloves && !target.gloves.canremove)
- message = "\red [source] fails to take off \a [target.gloves] from [target]'s hands!"
- return
- else
- message = "\red [source] is trying to take off the [target.gloves] from [target]'s hands!"
- if("eyes")
- target.attack_log += text("\[[time_stamp()]\] Has had their eyewear ([target.glasses]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) eyewear ([target.glasses])")
- if(target.glasses && !target.glasses.canremove)
- message = "\red [source] fails to take off \a [target.glasses] from [target]'s eyes!"
- return
- else
- message = "\red [source] is trying to take off the [target.glasses] from [target]'s eyes!"
- if("l_ear")
- target.attack_log += text("\[[time_stamp()]\] Has had their left ear item ([target.l_ear]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) left ear item ([target.l_ear])")
- if(target.l_ear && !target.l_ear.canremove)
- message = "\red [source] fails to take off \a [target.l_ear] from [target]'s left ear!"
- return
- else
- message = "\red [source] is trying to take off the [target.l_ear] from [target]'s left ear!"
- if("r_ear")
- target.attack_log += text("\[[time_stamp()]\] Has had their right ear item ([target.r_ear]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) right ear item ([target.r_ear])")
- if(target.r_ear && !target.r_ear.canremove)
- message = "\red [source] fails to take off \a [target.r_ear] from [target]'s right ear!"
- return
- else
- message = "\red [source] is trying to take off the [target.r_ear] from [target]'s right ear!"
- if("head")
- target.attack_log += text("\[[time_stamp()]\] Has had their hat ([target.head]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) hat ([target.head])")
- if(target.head && !target.head.canremove)
- message = "\red [source] fails to take off \a [target.head] from [target]'s head!"
- return
- else
- message = "\red [source] is trying to take off the [target.head] from [target]'s head!"
- if("shoes")
- target.attack_log += text("\[[time_stamp()]\] Has had their shoes ([target.shoes]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) shoes ([target.shoes])")
- if(target.shoes && !target.shoes.canremove)
- message = "\red [source] fails to take off \a [target.shoes] from [target]'s feet!"
- return
- else
- message = "\red [source] is trying to take off the [target.shoes] from [target]'s feet!"
- if("belt")
- target.attack_log += text("\[[time_stamp()]\] Has had their belt item ([target.belt]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) belt item ([target.belt])")
- if(!pickpocket)
- message = "\red [source] is trying to take off the [target.belt] from [target]'s belt!"
- else
- source << "\blue You try to take off the [target.belt] from [target]'s belt!"
- if("suit")
- target.attack_log += text("\[[time_stamp()]\] Has had their suit ([target.wear_suit]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) suit ([target.wear_suit])")
- if(target.wear_suit && !target.wear_suit.canremove)
- message = "\red [source] fails to take off \a [target.wear_suit] from [target]'s body!"
- return
- else
- message = "\red [source] is trying to take off \a [target.wear_suit] from [target]'s body!"
- if("back")
- target.attack_log += text("\[[time_stamp()]\] Has had their back item ([target.back]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) back item ([target.back])")
- message = "\red [source] is trying to take off \a [target.back] from [target]'s back!"
- if("handcuff")
- target.attack_log += text("\[[time_stamp()]\] Was unhandcuffed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to unhandcuff [target.name]'s ([target.ckey])")
+ var/message=null
+ switch(place)
+ if("syringe")
+ message = "\red [source] is trying to inject [target]!"
+ if("pill")
+ message = "\red [source] is trying to force [target] to swallow [item]!"
+ if("drink")
+ message = "\red [source] is trying to force [target] to swallow a gulp of [item]!"
+ if("dnainjector")
+ message = "\red [source] is trying to inject [target] with the [item]!"
+ if("mask")
+ target.attack_log += text("\[[time_stamp()]\] Had their mask removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) mask")
+ if(target.wear_mask && !target.wear_mask.canremove)
+ message = "\red [source] fails to take off \a [target.wear_mask] from [target]'s head!"
+ return
+ else
+ message = "\red [source] is trying to take off \a [target.wear_mask] from [target]'s head!"
+ if("l_hand")
+ target.attack_log += text("\[[time_stamp()]\] Has had their left hand item ([target.l_hand]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) left hand item ([target.l_hand])")
+ message = "\red [source] is trying to take off \a [target.l_hand] from [target]'s left hand!"
+ if("r_hand")
+ target.attack_log += text("\[[time_stamp()]\] Has had their right hand item ([target.r_hand]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) right hand item ([target.r_hand])")
+ message = "\red [source] is trying to take off \a [target.r_hand] from [target]'s right hand!"
+ if("gloves")
+ target.attack_log += text("\[[time_stamp()]\] Has had their gloves ([target.gloves]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) gloves ([target.gloves])")
+ if(target.gloves && !target.gloves.canremove)
+ message = "\red [source] fails to take off \a [target.gloves] from [target]'s hands!"
+ return
+ else
+ message = "\red [source] is trying to take off the [target.gloves] from [target]'s hands!"
+ if("eyes")
+ target.attack_log += text("\[[time_stamp()]\] Has had their eyewear ([target.glasses]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) eyewear ([target.glasses])")
+ if(target.glasses && !target.glasses.canremove)
+ message = "\red [source] fails to take off \a [target.glasses] from [target]'s eyes!"
+ return
+ else
+ message = "\red [source] is trying to take off the [target.glasses] from [target]'s eyes!"
+ if("l_ear")
+ target.attack_log += text("\[[time_stamp()]\] Has had their left ear item ([target.l_ear]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) left ear item ([target.l_ear])")
+ if(target.l_ear && !target.l_ear.canremove)
+ message = "\red [source] fails to take off \a [target.l_ear] from [target]'s left ear!"
+ return
+ else
+ message = "\red [source] is trying to take off the [target.l_ear] from [target]'s left ear!"
+ if("r_ear")
+ target.attack_log += text("\[[time_stamp()]\] Has had their right ear item ([target.r_ear]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) right ear item ([target.r_ear])")
+ if(target.r_ear && !target.r_ear.canremove)
+ message = "\red [source] fails to take off \a [target.r_ear] from [target]'s right ear!"
+ return
+ else
+ message = "\red [source] is trying to take off the [target.r_ear] from [target]'s right ear!"
+ if("head")
+ target.attack_log += text("\[[time_stamp()]\] Has had their hat ([target.head]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) hat ([target.head])")
+ if(target.head && !target.head.canremove)
+ message = "\red [source] fails to take off \a [target.head] from [target]'s head!"
+ return
+ else
+ message = "\red [source] is trying to take off the [target.head] from [target]'s head!"
+ if("shoes")
+ target.attack_log += text("\[[time_stamp()]\] Has had their shoes ([target.shoes]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) shoes ([target.shoes])")
+ if(target.shoes && !target.shoes.canremove)
+ message = "\red [source] fails to take off \a [target.shoes] from [target]'s feet!"
+ return
+ else
+ message = "\red [source] is trying to take off the [target.shoes] from [target]'s feet!"
+ if("belt")
+ target.attack_log += text("\[[time_stamp()]\] Has had their belt item ([target.belt]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) belt item ([target.belt])")
+ if(!pickpocket)
+ message = "\red [source] is trying to take off the [target.belt] from [target]'s belt!"
+ else
+ source << "\blue You try to take off the [target.belt] from [target]'s belt!"
+ if("suit")
+ target.attack_log += text("\[[time_stamp()]\] Has had their suit ([target.wear_suit]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) suit ([target.wear_suit])")
+ if(target.wear_suit && !target.wear_suit.canremove)
+ message = "\red [source] fails to take off \a [target.wear_suit] from [target]'s body!"
+ return
+ else
+ message = "\red [source] is trying to take off \a [target.wear_suit] from [target]'s body!"
+ if("back")
+ target.attack_log += text("\[[time_stamp()]\] Has had their back item ([target.back]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) back item ([target.back])")
+ message = "\red [source] is trying to take off \a [target.back] from [target]'s back!"
+ if("handcuff")
+ target.attack_log += text("\[[time_stamp()]\] Was unhandcuffed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to unhandcuff [target.name]'s ([target.ckey])")
+ if(target.handcuffed)
message = "\red [source] is trying to unhandcuff [target]!"
- if("legcuff")
- target.attack_log += text("\[[time_stamp()]\] Was unlegcuffed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to unlegcuff [target.name]'s ([target.ckey])")
+ else
+ message = "\red [source] is trying to handcuff [target]!"
+ if("legcuff")
+ target.attack_log += text("\[[time_stamp()]\] Was unlegcuffed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to unlegcuff [target.name]'s ([target.ckey])")
+ if(target.legcuffed)
message = "\red [source] is trying to unlegcuff [target]!"
- if("uniform")
- target.attack_log += text("\[[time_stamp()]\] Has had their uniform ([target.w_uniform]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) uniform ([target.w_uniform])")
- for(var/obj/item/I in list(target.l_store, target.r_store))
- if(I.on_found(source))
- return
- if(target.w_uniform && !target.w_uniform.canremove)
- message = "\red [source] fails to take off \a [target.w_uniform] from [target]'s body!"
+ else
+ message = "\red [source] is trying to legcuff [target]!"
+ if("uniform")
+ target.attack_log += text("\[[time_stamp()]\] Has had their uniform ([target.w_uniform]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) uniform ([target.w_uniform])")
+ for(var/obj/item/I in list(target.l_store, target.r_store))
+ if(I.on_found(source))
return
- else
- message = "\red [source] is trying to take off \a [target.w_uniform] from [target]'s body!"
- if("s_store")
- target.attack_log += text("\[[time_stamp()]\] Has had their suit storage item ([target.s_store]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) suit storage item ([target.s_store])")
- message = "\red [source] is trying to take off \a [target.s_store] from [target]'s suit!"
- if("pockets")
- target.attack_log += text("\[[time_stamp()]\] Has had their pockets emptied by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to empty [target.name]'s ([target.ckey]) pockets")
- for(var/obj/item/I in list(target.l_store, target.r_store))
- if(I.on_found(source))
- return
- message = "\red [source] is trying to empty [target]'s pockets."
- if("CPR")
- if (!target.cpr_time)
- del(src)
- target.cpr_time = 0
- message = "\red [source] is trying perform CPR on [target]!"
- if("id")
- target.attack_log += text("\[[time_stamp()]\] Has had their ID ([target.wear_id]) removed by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) ID ([target.wear_id])")
- if(!pickpocket)
- message = "\red [source] is trying to take off [target.wear_id] from [target]'s uniform!"
- else
- source << "\blue You try to take off [target.wear_id] from [target]'s uniform!"
- if("internal")
- target.attack_log += text("\[[time_stamp()]\] Has had their internals toggled by [source.name] ([source.ckey])")
- source.attack_log += text("\[[time_stamp()]\] Attempted to toggle [target.name]'s ([target.ckey]) internals")
- if (target.internal)
- message = "\red [source] is trying to remove [target]'s internals"
- else
- message = "\red [source] is trying to set on [target]'s internals."
- if("splints")
- message = text("\red [] is trying to remove []'s splints!", source, target)
+ if(target.w_uniform && !target.w_uniform.canremove)
+ message = "\red [source] fails to take off \a [target.w_uniform] from [target]'s body!"
+ return
+ else
+ message = "\red [source] is trying to take off \a [target.w_uniform] from [target]'s body!"
+ if("s_store")
+ target.attack_log += text("\[[time_stamp()]\] Has had their suit storage item ([target.s_store]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) suit storage item ([target.s_store])")
+ message = "\red [source] is trying to take off \a [target.s_store] from [target]'s suit!"
+ if("pockets")
+ target.attack_log += text("\[[time_stamp()]\] Has had their pockets emptied by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to empty [target.name]'s ([target.ckey]) pockets")
+ for(var/obj/item/I in list(target.l_store, target.r_store))
+ if(I.on_found(source))
+ return
+ message = "\red [source] is trying to empty [target]'s pockets."
+ if("CPR")
+ if (!target.cpr_time)
+ del(src)
+ target.cpr_time = 0
+ message = "\red [source] is trying perform CPR on [target]!"
+ if("id")
+ target.attack_log += text("\[[time_stamp()]\] Has had their ID ([target.wear_id]) removed by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to remove [target.name]'s ([target.ckey]) ID ([target.wear_id])")
+ if(!pickpocket)
+ message = "\red [source] is trying to take off [target.wear_id] from [target]'s uniform!"
+ else
+ source << "\blue You try to take off [target.wear_id] from [target]'s uniform!"
+ if("internal")
+ target.attack_log += text("\[[time_stamp()]\] Has had their internals toggled by [source.name] ([source.ckey])")
+ source.attack_log += text("\[[time_stamp()]\] Attempted to toggle [target.name]'s ([target.ckey]) internals")
+ if (target.internal)
+ message = "\red [source] is trying to remove [target]'s internals"
+ else
+ message = "\red [source] is trying to set on [target]'s internals."
+ if("splints")
+ message = text("\red [] is trying to remove []'s splints!", source, target)
- for(var/mob/M in viewers(target, null))
+ for(var/mob/M in viewers(target, null))
+ if(findtext(message, "is trying to take off from", 1, 0) > 0)
+ M.show_message("\red [source] is trying to put \a [item] on [target]", 1)
+ else
M.show_message(message, 1)
spawn( HUMAN_STRIP_DELAY )
done()