mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-21 13:05:36 +01:00
Mobs each now have a unique tag which are not after they are deleted (unlike byond's \ref[] macro)
Since tag replaces the output of the \ref[] macro, this means that menus which use hrefs with \ref[mob] will no longer be able to accidentally link to the wrong mob. The tags are of the form "mob_475" etc Admin_pms now use ckey instead of client-reference. This means that PMs will no longer accidentally get sent to the wrong people. There is no risk of players using hrefs to send adminhelps to known admin ckeys to see if they are online (as I'd already changed the PM system to not tell non-admin users whom received their message). key_name() now accepts text input (key or ckey) - it is slightly more efficient to feed it a client or mob however! This functionality is provided to allow certain admintools to become more robust when we want to talk about e.g. a griefer whom has just DCed whom no-longer has a corpse (no client/mob...just a ckey reference). key_name() now reports DCed players properly.
This commit is contained in:
@@ -35,12 +35,17 @@
|
||||
|
||||
//takes input from cmd_admin_pm_context, cmd_admin_pm_panel or /client/Topic and sends them a PM.
|
||||
//Fetching a message if needed. src is the sender and C is the target client
|
||||
/client/proc/cmd_admin_pm(var/client/C, var/msg)
|
||||
/client/proc/cmd_admin_pm(whom, msg)
|
||||
if(prefs.muted & MUTE_ADMINHELP)
|
||||
src << "<font color='red'>Error: Admin-PM: You are unable to use admin PM-s (muted).</font>"
|
||||
return
|
||||
|
||||
if(!istype(C,/client))
|
||||
|
||||
var/client/C
|
||||
if(istext(whom))
|
||||
C = directory[whom]
|
||||
else if(istype(whom,/client))
|
||||
C = whom
|
||||
if(!C)
|
||||
if(holder) src << "<font color='red'>Error: Admin-PM: Client not found.</font>"
|
||||
else adminhelp(msg) //admin we are replying to left. adminhelp instead
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user