mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 18:22:39 +00:00
Adds a config option MENTORS which sets the variable config.mods_are_mentors Adds a rights level of R_MENTOR which gets msay, private message, aghost, notes, and a new proc for checking for new players (requires database support). If the confic option for mentors is set then the ckeys listed in moderators.txt file will instead be set as mentors, you can still make moderators by adding them in admins.txt staffwho will show Mentors instead of Moderators as the heading above the listing of non-admins. Also: Players now get a message gently reminding them to click the name of the staff member to reply instead of ahelping over and over.
42 lines
1.5 KiB
Plaintext
42 lines
1.5 KiB
Plaintext
/client/proc/cmd_admin_say(msg as text)
|
|
set category = "Special Verbs"
|
|
set name = "Asay" //Gave this shit a shorter name so you only have to time out "asay" rather than "admin say" to use it --NeoFite
|
|
set hidden = 1
|
|
if(!check_rights(R_ADMIN)) return
|
|
|
|
msg = copytext(sanitize(msg), 1, MAX_MESSAGE_LEN)
|
|
if(!msg) return
|
|
|
|
log_admin("[key_name(src)] : [msg]")
|
|
|
|
if(check_rights(R_ADMIN,0))
|
|
msg = "<span class='adminsay'><span class='prefix'>ADMIN:</span> <EM>[key_name(usr, 1)]</EM> (<a href='?_src_=holder;adminplayerobservejump=\ref[mob]'>JMP</A>): <span class='message'>[msg]</span></span>"
|
|
for(var/client/C in admins)
|
|
if(R_ADMIN & C.holder.rights)
|
|
C << msg
|
|
|
|
feedback_add_details("admin_verb","M") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
|
|
|
/client/proc/cmd_mod_say(msg as text)
|
|
set category = "Special Verbs"
|
|
set name = "Msay"
|
|
set hidden = 1
|
|
|
|
if(!check_rights(R_ADMIN|R_MOD|R_MENTOR)) return
|
|
|
|
msg = copytext(sanitize(msg), 1, MAX_MESSAGE_LEN)
|
|
log_admin("MOD: [key_name(src)] : [msg]")
|
|
|
|
if (!msg)
|
|
return
|
|
var/color = "mod"
|
|
if (check_rights(R_ADMIN,0))
|
|
color = "adminmod"
|
|
|
|
var/channel = "MOD:"
|
|
if(config.mods_are_mentors)
|
|
channel = "MENTOR:"
|
|
for(var/client/C in admins)
|
|
if((R_ADMIN|R_MOD|R_MENTOR) & C.holder.rights)
|
|
C << "<span class='[color]'><span class='prefix'>[channel]</span> <EM>[key_name(src,1)]</EM> (<A HREF='?src=\ref[C.holder];adminplayerobservejump=\ref[mob]'>JMP</A>): <span class='message'>[msg]</span></span>"
|