mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 18:32:03 +00:00
Okay in relation to the previous commit r2391 muting is now tied to clients and not mobs. So if you get muted as a human and then die and change into a ghost you will no longer 'loose' your mute.
git-svn-id: http://tgstation13.googlecode.com/svn/trunk@2392 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -8,6 +8,9 @@
|
|||||||
var/seeprayers = 0
|
var/seeprayers = 0
|
||||||
//Hosts can change their color
|
//Hosts can change their color
|
||||||
var/ooccolor = "#b82e00"
|
var/ooccolor = "#b82e00"
|
||||||
|
var/muted = null //Can't talk in OOC, say, whisper, emote... anything except for adminhelp and admin-pm. An admin punishment
|
||||||
|
var/muted_complete = null //Can't talk in any way shape or form (muted + can't adminhelp or respond to admin pm-s). An admin punishment
|
||||||
|
|
||||||
|
|
||||||
//END Admin Things
|
//END Admin Things
|
||||||
|
|
||||||
|
|||||||
@@ -118,8 +118,6 @@
|
|||||||
|
|
||||||
var/miming = null //checks if the guy is a mime//Human
|
var/miming = null //checks if the guy is a mime//Human
|
||||||
var/silent = null //Can't talk. Value goes down every life proc.//Human
|
var/silent = null //Can't talk. Value goes down every life proc.//Human
|
||||||
var/muted = null //Can't talk in OOC, say, whisper, emote... anything except for adminhelp and admin-pm. An admin punishment
|
|
||||||
var/muted_complete = null //Can't talk in any way shape or form (muted + can't adminhelp or respond to admin pm-s). An admin punishment
|
|
||||||
|
|
||||||
var/obj/hud/hud_used = null
|
var/obj/hud/hud_used = null
|
||||||
|
|
||||||
|
|||||||
@@ -25,7 +25,7 @@
|
|||||||
else if (!dooc_allowed && !src.client.holder && (src.client.deadchat != 0))
|
else if (!dooc_allowed && !src.client.holder && (src.client.deadchat != 0))
|
||||||
usr << "OOC for dead mobs has been turned off."
|
usr << "OOC for dead mobs has been turned off."
|
||||||
return
|
return
|
||||||
else if (src.muted || src.muted_complete)
|
else if (src.client && (src.client.muted || src.client.muted_complete))
|
||||||
src << "You are muted."
|
src << "You are muted."
|
||||||
return
|
return
|
||||||
else if (findtext(msg, "byond://") && !src.client.holder)
|
else if (findtext(msg, "byond://") && !src.client.holder)
|
||||||
|
|||||||
@@ -377,10 +377,13 @@
|
|||||||
if ((M.client && M.client.holder && (M.client.holder.level >= src.level)))
|
if ((M.client && M.client.holder && (M.client.holder.level >= src.level)))
|
||||||
alert("You cannot perform this action. You must be of a higher administrative rank!", null, null, null, null, null)
|
alert("You cannot perform this action. You must be of a higher administrative rank!", null, null, null, null, null)
|
||||||
return
|
return
|
||||||
M.muted = !M.muted
|
if(!M.client)
|
||||||
log_admin("[key_name(usr)] has [(M.muted ? "muted" : "voiced")] [key_name(M)].")
|
src << "This mob doesn't have a client tied to it."
|
||||||
message_admins("\blue [key_name_admin(usr)] has [(M.muted ? "muted" : "voiced")] [key_name_admin(M)].", 1)
|
return
|
||||||
M << "You have been [(M.muted ? "muted" : "voiced")]. Please resolve this in adminhelp."
|
M.client.muted = !M.client.muted
|
||||||
|
log_admin("[key_name(usr)] has [(M.client.muted ? "muted" : "voiced")] [key_name(M)].")
|
||||||
|
message_admins("\blue [key_name_admin(usr)] has [(M.client.muted ? "muted" : "voiced")] [key_name_admin(M)].", 1)
|
||||||
|
M << "You have been [(M.client.muted ? "muted" : "voiced")]. Please resolve this in adminhelp."
|
||||||
if (href_list["mute_complete"])
|
if (href_list["mute_complete"])
|
||||||
if ((src.rank in list( "Moderator", "Temporary Admin", "Admin Candidate", "Trial Admin", "Badmin", "Game Admin", "Game Master" )))
|
if ((src.rank in list( "Moderator", "Temporary Admin", "Admin Candidate", "Trial Admin", "Badmin", "Game Admin", "Game Master" )))
|
||||||
var/mob/M = locate(href_list["mute_complete"])
|
var/mob/M = locate(href_list["mute_complete"])
|
||||||
@@ -388,10 +391,13 @@
|
|||||||
if ((M.client && M.client.holder && (M.client.holder.level >= src.level)))
|
if ((M.client && M.client.holder && (M.client.holder.level >= src.level)))
|
||||||
alert("You cannot perform this action. You must be of a higher administrative rank!", null, null, null, null, null)
|
alert("You cannot perform this action. You must be of a higher administrative rank!", null, null, null, null, null)
|
||||||
return
|
return
|
||||||
M.muted_complete = !M.muted_complete
|
if(!M.client)
|
||||||
log_admin("[key_name(usr)] has [(M.muted_complete ? "completely muted" : "voiced (complete)")] [key_name(M)].")
|
src << "This mob doesn't have a client tied to it."
|
||||||
message_admins("\blue [key_name_admin(usr)] has [(M.muted_complete ? "completely muted" : "voiced (complete)")] [key_name_admin(M)].", 1)
|
return
|
||||||
M << "You have been [(M.muted_complete ? "completely muted" : "voiced (complete)")]. You are unable to speak or even adminhelp"
|
M.client.muted_complete = !M.client.muted_complete
|
||||||
|
log_admin("[key_name(usr)] has [(M.client.muted_complete ? "completely muted" : "voiced (complete)")] [key_name(M)].")
|
||||||
|
message_admins("\blue [key_name_admin(usr)] has [(M.client.muted_complete ? "completely muted" : "voiced (complete)")] [key_name_admin(M)].", 1)
|
||||||
|
M << "You have been [(M.client.muted_complete ? "completely muted" : "voiced (complete)")]. You are unable to speak or even adminhelp"
|
||||||
|
|
||||||
if (href_list["c_mode"])
|
if (href_list["c_mode"])
|
||||||
if ((src.rank in list( "Temporary Admin", "Admin Candidate", "Trial Admin", "Badmin", "Game Admin", "Game Master" )))
|
if ((src.rank in list( "Temporary Admin", "Admin Candidate", "Trial Admin", "Badmin", "Game Admin", "Game Master" )))
|
||||||
@@ -1689,8 +1695,11 @@
|
|||||||
else
|
else
|
||||||
foo += text("<B>Hasn't Entered Game</B> | ")
|
foo += text("<B>Hasn't Entered Game</B> | ")
|
||||||
foo += text("<A href='?src=\ref[src];forcespeech=\ref[M]'>Forcesay</A> | ")
|
foo += text("<A href='?src=\ref[src];forcespeech=\ref[M]'>Forcesay</A> | ")
|
||||||
foo += text("<A href='?src=\ref[src];mute2=\ref[M]'>Mute: [(M.muted ? "Muted" : "Voiced")]</A> | ")
|
if(M.client)
|
||||||
foo += text("<A href='?src=\ref[src];mute_complete=\ref[M]'>Complete mute: [(M.muted ? "Completely Muted" : "Voiced")]</A> | ")
|
foo += text("<A href='?src=\ref[src];mute2=\ref[M]'>Mute: [(M.client.muted ? "Muted" : "Voiced")]</A> | ")
|
||||||
|
foo += text("<A href='?src=\ref[src];mute_complete=\ref[M]'>Complete mute: [(M.client.muted ? "Completely Muted" : "Voiced")]</A> | ")
|
||||||
|
else
|
||||||
|
foo += "Mute unavailable - no client"
|
||||||
foo += text("<A href='?src=\ref[src];boot2=\ref[M]'>Boot</A>")
|
foo += text("<A href='?src=\ref[src];boot2=\ref[M]'>Boot</A>")
|
||||||
foo += text("<br>")
|
foo += text("<br>")
|
||||||
foo += text("<A href='?src=\ref[src];jumpto=\ref[M]'>Jump to</A> | ")
|
foo += text("<A href='?src=\ref[src];jumpto=\ref[M]'>Jump to</A> | ")
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
if (!msg)
|
if (!msg)
|
||||||
return
|
return
|
||||||
|
|
||||||
if (usr.muted_complete)
|
if (usr.client && usr.client.muted_complete)
|
||||||
return
|
return
|
||||||
|
|
||||||
for (var/mob/M in world)
|
for (var/mob/M in world)
|
||||||
|
|||||||
@@ -9,7 +9,8 @@
|
|||||||
src << "Only administrators may use this command."
|
src << "Only administrators may use this command."
|
||||||
return
|
return
|
||||||
|
|
||||||
if (!src.mob || src.mob.muted || src.mob.muted_complete)
|
if (src.muted || src.muted_complete)
|
||||||
|
src << "You are muted."
|
||||||
return
|
return
|
||||||
|
|
||||||
msg = copytext(sanitize(msg), 1, MAX_MESSAGE_LEN)
|
msg = copytext(sanitize(msg), 1, MAX_MESSAGE_LEN)
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
return
|
return
|
||||||
if(!src.mob)
|
if(!src.mob)
|
||||||
return
|
return
|
||||||
if(src.mob.muted || src.mob.muted_complete)
|
if(src.muted || src.muted_complete)
|
||||||
return
|
return
|
||||||
|
|
||||||
msg = copytext(sanitize(msg), 1, MAX_MESSAGE_LEN)
|
msg = copytext(sanitize(msg), 1, MAX_MESSAGE_LEN)
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
if (!msg)
|
if (!msg)
|
||||||
return
|
return
|
||||||
|
|
||||||
if (usr.muted || src.muted_complete)
|
if (usr.client && (usr.client.muted || usr.client.muted_complete))
|
||||||
return
|
return
|
||||||
|
|
||||||
var/icon/cross = icon('storage.dmi',"bible")
|
var/icon/cross = icon('storage.dmi',"bible")
|
||||||
|
|||||||
@@ -91,7 +91,7 @@
|
|||||||
src << "Only administrators may use this command."
|
src << "Only administrators may use this command."
|
||||||
return
|
return
|
||||||
if(M)
|
if(M)
|
||||||
if(src.mob.muted_complete)
|
if(src.muted_complete)
|
||||||
src << "You are muted have a nice day"
|
src << "You are muted have a nice day"
|
||||||
return
|
return
|
||||||
if (!( ismob(M) ))
|
if (!( ismob(M) ))
|
||||||
@@ -142,12 +142,15 @@
|
|||||||
if (M.client && M.client.holder && (M.client.holder.level >= holder.level))
|
if (M.client && M.client.holder && (M.client.holder.level >= holder.level))
|
||||||
alert("You cannot perform this action. You must be of a higher administrative rank!", null, null, null, null, null)
|
alert("You cannot perform this action. You must be of a higher administrative rank!", null, null, null, null, null)
|
||||||
return
|
return
|
||||||
M.muted = !M.muted
|
if(!M.client)
|
||||||
|
src << "This mob doesn't have a client tied to it."
|
||||||
|
return
|
||||||
|
M.client.muted = !M.client.muted
|
||||||
|
|
||||||
log_admin("[key_name(src)] has [(M.muted ? "muted" : "voiced")] [key_name(M)].")
|
log_admin("[key_name(src)] has [(M.client.muted ? "muted" : "voiced")] [key_name(M)].")
|
||||||
message_admins("[key_name_admin(src)] has [(M.muted ? "muted" : "voiced")] [key_name_admin(M)].", 1)
|
message_admins("[key_name_admin(src)] has [(M.client.muted ? "muted" : "voiced")] [key_name_admin(M)].", 1)
|
||||||
|
|
||||||
M << "You have been [(M.muted ? "muted" : "voiced")]."
|
M << "You have been [(M.client.muted ? "muted" : "voiced")]."
|
||||||
|
|
||||||
|
|
||||||
/client/proc/cmd_admin_add_random_ai_law()
|
/client/proc/cmd_admin_add_random_ai_law()
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
log_say("Ghost/[src.key] : [message]")
|
log_say("Ghost/[src.key] : [message]")
|
||||||
|
|
||||||
if (src.muted || src.muted_complete)
|
if (src.client && (src.client.muted || src.client.muted_complete))
|
||||||
src << "You are muted."
|
src << "You are muted."
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|||||||
@@ -62,7 +62,9 @@
|
|||||||
message = "<B>[src]</B> [input]"
|
message = "<B>[src]</B> [input]"
|
||||||
|
|
||||||
if ("me")
|
if ("me")
|
||||||
if (muted || silent || muted_complete)
|
if(silent)
|
||||||
|
return
|
||||||
|
if (src.client && (client.muted || client.muted_complete))
|
||||||
src << "You are muted."
|
src << "You are muted."
|
||||||
return
|
return
|
||||||
if (stat)
|
if (stat)
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
log_whisper("[src.name]/[src.key] : [message]")
|
log_whisper("[src.name]/[src.key] : [message]")
|
||||||
|
|
||||||
if (src.muted || src.muted_complete)
|
if (src.client && (src.client.muted || src.client.muted_complete))
|
||||||
src << "You are muted."
|
src << "You are muted."
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|||||||
@@ -30,7 +30,10 @@
|
|||||||
if (stat == 2)
|
if (stat == 2)
|
||||||
return say_dead(message)
|
return say_dead(message)
|
||||||
|
|
||||||
if (muted || silent || src.muted_complete)
|
if (silent)
|
||||||
|
return
|
||||||
|
|
||||||
|
if (src.client && (client.muted || src.client.muted_complete))
|
||||||
src << "You are muted."
|
src << "You are muted."
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
if (!message)
|
if (!message)
|
||||||
return
|
return
|
||||||
|
|
||||||
if (muted || src.muted_complete)
|
if (src.client && (client.muted || src.client.muted_complete))
|
||||||
src << "You are muted."
|
src << "You are muted."
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|||||||
@@ -578,7 +578,7 @@
|
|||||||
if(href_list["priv_msg"])
|
if(href_list["priv_msg"])
|
||||||
var/mob/M = locate(href_list["priv_msg"])
|
var/mob/M = locate(href_list["priv_msg"])
|
||||||
if(M)
|
if(M)
|
||||||
if(muted_complete)
|
if(src.client && client.muted_complete)
|
||||||
src << "You are muted have a nice day"
|
src << "You are muted have a nice day"
|
||||||
return
|
return
|
||||||
if (!ismob(M))
|
if (!ismob(M))
|
||||||
|
|||||||
Reference in New Issue
Block a user