mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-02-04 05:08:26 +00:00
Adds a system adapted from Aurora that will automatically mute someone if they say things too quickly in IC, OOC, Deadchat, Ahelp, or Pray.
62 lines
2.0 KiB
Plaintext
62 lines
2.0 KiB
Plaintext
/mob/observer/dead/say(var/message)
|
|
message = sanitize(message)
|
|
|
|
if (!message)
|
|
return
|
|
|
|
log_say("Ghost/[src.key] : [message]")
|
|
|
|
if (src.client)
|
|
client.handle_spam_prevention(MUTE_DEADCHAT)
|
|
if(src.client.prefs.muted & MUTE_DEADCHAT)
|
|
src << "\red You cannot talk in deadchat (muted)."
|
|
return
|
|
|
|
. = src.say_dead(message)
|
|
|
|
|
|
/mob/observer/dead/emote(var/act, var/type, var/message)
|
|
//message = sanitize(message) - already sanitized in verb/me_verb()
|
|
|
|
if(!message)
|
|
return
|
|
|
|
if(act != "me")
|
|
return
|
|
|
|
log_emote("Ghost/[src.key] : [message]")
|
|
|
|
if(src.client)
|
|
client.handle_spam_prevention(MUTE_DEADCHAT)
|
|
if(src.client.prefs.muted & MUTE_DEADCHAT)
|
|
src << "\red You cannot emote in deadchat (muted)."
|
|
return
|
|
|
|
. = src.emote_dead(message)
|
|
|
|
/*
|
|
for (var/mob/M in hearers(null, null))
|
|
if (!M.stat)
|
|
if(M.job == "Chaplain")
|
|
if (prob (49))
|
|
M.show_message("<span class='game'><i>You hear muffled speech... but nothing is there...</i></span>", 2)
|
|
if(prob(20))
|
|
playsound(src.loc, pick('sound/effects/ghost.ogg','sound/effects/ghost2.ogg'), 10, 1)
|
|
else
|
|
M.show_message("<span class='game'><i>You hear muffled speech... you can almost make out some words...</i></span>", 2)
|
|
// M.show_message("<span class='game'><i>[stutter(message)]</i></span>", 2)
|
|
if(prob(30))
|
|
playsound(src.loc, pick('sound/effects/ghost.ogg','sound/effects/ghost2.ogg'), 10, 1)
|
|
else
|
|
if (prob(50))
|
|
return
|
|
else if (prob (95))
|
|
M.show_message("<span class='game'><i>You hear muffled speech... but nothing is there...</i></span>", 2)
|
|
if(prob(20))
|
|
playsound(src.loc, pick('sound/effects/ghost.ogg','sound/effects/ghost2.ogg'), 10, 1)
|
|
else
|
|
M.show_message("<span class='game'><i>You hear muffled speech... you can almost make out some words...</i></span>", 2)
|
|
// M.show_message("<span class='game'><i>[stutter(message)]</i></span>", 2)
|
|
playsound(src.loc, pick('sound/effects/ghost.ogg','sound/effects/ghost2.ogg'), 10, 1)
|
|
*/
|