Merge pull request #16648 from AffectedArc07/mutes-glob

Moves mutes to a GLOB
This commit is contained in:
Fox McCloud
2021-09-08 09:01:13 -04:00
committed by GitHub
20 changed files with 68 additions and 37 deletions
+1 -1
View File
@@ -19,7 +19,7 @@
log_ghostemote(message, src)
if(src.client)
if(src.client.prefs.muted & MUTE_DEADCHAT)
if(check_mute(client.ckey, MUTE_DEADCHAT))
to_chat(src, "<span class='warning'>You cannot emote in deadchat (muted).</span>")
return
+1 -1
View File
@@ -112,7 +112,7 @@
O.show_message(message, m_type)
/mob/proc/emote_dead(message)
if(client.prefs.muted & MUTE_DEADCHAT)
if(check_mute(client.ckey, MUTE_DEADCHAT))
to_chat(src, "<span class='warning'>You cannot send deadchat emotes (muted).</span>")
return
@@ -14,10 +14,10 @@
if(silent)
return
if(src.client)
if(client.prefs.muted & MUTE_IC)
if(check_mute(client.ckey, MUTE_IC))
to_chat(src, "<span class='warning'>You cannot send IC messages (muted).</span>")
return
if(src.client.handle_spam_prevention(message,MUTE_IC))
if(src.client.handle_spam_prevention(message, MUTE_IC))
return
if(stat)
return
+3 -3
View File
@@ -110,7 +110,7 @@ GLOBAL_LIST_EMPTY(channel_to_radio_key)
/mob/living/say(message, verb = "says", sanitize = TRUE, ignore_speech_problems = FALSE, ignore_atmospherics = FALSE, ignore_languages = FALSE)
if(client)
if(client.prefs.muted & MUTE_IC)
if(check_mute(client.ckey, MUTE_IC))
to_chat(src, "<span class='danger'>You cannot speak in IC (Muted).</span>")
return
@@ -297,7 +297,7 @@ GLOBAL_LIST_EMPTY(channel_to_radio_key)
/mob/living/emote(act, type, message, force) //emote code is terrible, this is so that anything that isn't already snowflaked to shit can call the parent and handle emoting sanely
if(client)
if(client.prefs.muted & MUTE_IC)
if(check_mute(client.ckey, MUTE_IC))
to_chat(src, "<span class='danger'>You cannot speak in IC (Muted).</span>")
return
@@ -352,7 +352,7 @@ GLOBAL_LIST_EMPTY(channel_to_radio_key)
/mob/living/proc/whisper_say(list/message_pieces, verb = "whispers")
if(client)
if(client.prefs.muted & MUTE_IC)
if(check_mute(client.ckey, MUTE_IC))
to_chat(src, "<span class='danger'>You cannot speak in IC (Muted).</span>")
return
@@ -19,10 +19,10 @@
if(silent)
return
if(src.client)
if(client.prefs.muted & MUTE_IC)
if(check_mute(client.ckey, MUTE_IC))
to_chat(src, "<span class='warning'>You cannot send IC messages (muted).</span>")
return
if(src.client.handle_spam_prevention(message,MUTE_IC))
if(src.client.handle_spam_prevention(message, MUTE_IC))
return
if(stat)
return
+1 -1
View File
@@ -51,7 +51,7 @@
to_chat(src, "<span class='danger'>Deadchat is globally muted.</span>")
return
if(client.prefs.muted & MUTE_DEADCHAT)
if(check_mute(client.ckey, MUTE_DEADCHAT))
to_chat(src, "<span class='warning'>You cannot talk in deadchat (muted).</span>")
return