mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-27 22:17:32 +01:00
Initial muzzle and emote changes
This commit is contained in:
@@ -121,6 +121,69 @@
|
||||
security_lock = TRUE
|
||||
locked = FALSE
|
||||
|
||||
/obj/item/clothing/mask/muzzle/safety/shock
|
||||
name = "shock muzzle"
|
||||
desc = "A muzzle designed to prevent biting. This one is fitted with a behavior correction system."
|
||||
var/obj/item/assembly/trigger = null
|
||||
origin_tech = "materials=1;engineering=1"
|
||||
|
||||
/obj/item/clothing/mask/muzzle/safety/shock/attackby(obj/item/W, mob/user, params)
|
||||
if(isscrewdriver(W))
|
||||
to_chat(user, "<span class='notice'>You disassemble [src].</span>")
|
||||
trigger.forceMove(get_turf(user))
|
||||
trigger.master = null
|
||||
trigger.holder = null
|
||||
trigger = null
|
||||
else if(trigger)
|
||||
to_chat(user, "<span class='notice'>Something is already attached to [src].</span>")
|
||||
else if(istype(W, /obj/item/assembly/signaler) || istype(W, /obj/item/assembly/voice))
|
||||
user.drop_item()
|
||||
trigger = W
|
||||
trigger.forceMove(src)
|
||||
trigger.master = src
|
||||
trigger.holder = src
|
||||
to_chat(user, "<span class='notice'>You attach the [W] to [src].</span>")
|
||||
else
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/item/clothing/mask/muzzle/safety/shock/equipped(obj/item/clothing/C)
|
||||
if(istype(C))
|
||||
if(isliving(C.loc))
|
||||
return C.loc
|
||||
else if(isliving(loc))
|
||||
return loc
|
||||
return FALSE
|
||||
|
||||
/obj/item/clothing/mask/muzzle/safety/shock/proc/process_activation(var/obj/D, var/normal = 1, var/special = 1)
|
||||
visible_message("[bicon(src)] *beep* *beep*", "*beep* *beep*")
|
||||
if(equipped(loc))
|
||||
var/mob/M = equipped(loc)
|
||||
to_chat(M, "<span class='danger'>You feel a sharp shock!</span>")
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(3, 1, M)
|
||||
s.start()
|
||||
|
||||
M.Weaken(5)
|
||||
if(ishuman(M))
|
||||
M.Stuttering(1)
|
||||
M.Jitter(20)
|
||||
return
|
||||
|
||||
/obj/item/clothing/mask/muzzle/safety/shock/HasProximity(atom/movable/AM as mob|obj)
|
||||
if(trigger)
|
||||
trigger.HasProximity(AM)
|
||||
|
||||
|
||||
/obj/item/clothing/mask/muzzle/safety/shock/hear_talk(mob/living/M as mob, msg)
|
||||
if(trigger)
|
||||
trigger.hear_talk(M, msg)
|
||||
|
||||
/obj/item/clothing/mask/muzzle/safety/shock/hear_message(mob/living/M as mob, msg)
|
||||
if(trigger)
|
||||
trigger.hear_message(M, msg)
|
||||
|
||||
|
||||
|
||||
/obj/item/clothing/mask/surgical
|
||||
name = "sterile mask"
|
||||
|
||||
@@ -31,8 +31,13 @@
|
||||
to_chat(usr, "You are unable to emote.")
|
||||
return
|
||||
|
||||
var/muzzled = istype(src.wear_mask, /obj/item/clothing/mask/muzzle)
|
||||
if(m_type == 2 && muzzled) return
|
||||
var/muzzled = is_muzzled()
|
||||
if(muzzled)
|
||||
var/obj/item/clothing/mask/muzzle/M = wear_mask
|
||||
if(M.mute)
|
||||
return //Not all muzzles block sound
|
||||
if(m_type == 2 && !can_speak())
|
||||
return
|
||||
|
||||
var/input
|
||||
if(!message)
|
||||
|
||||
@@ -10,6 +10,10 @@
|
||||
act = copytext(act, 1, t1)
|
||||
|
||||
var/muzzled = is_muzzled()
|
||||
if(muzzled)
|
||||
var/obj/item/clothing/mask/muzzle/M = wear_mask
|
||||
if(!M.mute)
|
||||
muzzled = 0 //Not all muzzles block sound
|
||||
if(!can_speak())
|
||||
muzzled = 1
|
||||
//var/m_type = 1
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
|
||||
// Whether the mob is capable of talking
|
||||
/mob/living/can_speak()
|
||||
return !(silent || (disabilities & MUTE) || is_muzzled())
|
||||
return !(silent || (disabilities & MUTE))
|
||||
|
||||
// Whether the mob is capable of standing or not
|
||||
/mob/living/proc/can_stand()
|
||||
|
||||
Reference in New Issue
Block a user