Adds mentors

This commit is contained in:
Casey
2022-08-14 15:09:27 -04:00
committed by CHOMPStation2
parent 79465280e1
commit 529616b1aa
13 changed files with 1879 additions and 17 deletions

View File

@@ -60,6 +60,14 @@
cmd_admin_pm(C,null)
return
if(href_list["mentorhelp_msg"])
var/client/C = locate(href_list["mentorhelp_msg"])
if(ismob(C))
var/mob/M = C
C = M.client
cmd_mentor_pm(C, null)
return
if(href_list["irc_msg"])
if(!holder && received_irc_pm < world.time - 6000) //Worse they can do is spam IRC for 10 minutes
to_chat(usr, "<span class='warning'>You are no longer able to use this, it's been more then 10 minutes since an admin on IRC has responded to you</span>")
@@ -123,6 +131,7 @@
switch(href_list["_src_"])
if("holder") hsrc = holder
if("mentorholder") hsrc = (check_rights(R_ADMIN, 0) ? holder : mentorholder)
if("usr") hsrc = mob
if("prefs") return prefs.process_link(usr,href_list)
if("vars") return view_var_Topic(href,href_list,hsrc)
@@ -185,6 +194,10 @@
GLOB.admins += src
holder.owner = src
mentorholder = mentor_datums[ckey]
if (mentorholder)
mentorholder.associate(GLOB.directory[ckey])
//preferences datum - also holds some persistant data for the client (because we may as well keep these datums to a minimum)
prefs = preferences_datums[ckey]
if(!prefs)
@@ -262,6 +275,9 @@
if(holder)
holder.owner = null
GLOB.admins -= src
if (mentorholder)
mentorholder.owner = null
GLOB.mentors -= src
GLOB.ahelp_tickets.ClientLogout(src)
GLOB.directory -= ckey
GLOB.clients -= src