Skip to content
This repository was archived by the owner on May 22, 2025. It is now read-only.

Commit 0bacaf9

Browse files
authored
Panel (#22951)
1 parent 47c1534 commit 0bacaf9

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

yogstation/code/modules/mentor/mentor_verbs.dm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ GLOBAL_LIST_INIT(mentor_verbs, list(
33
/client/proc/show_mentor_memo,
44
/client/proc/show_mentor_tickets,
55
/client/proc/cmd_mentor_pm_context,
6+
/client/proc/cmd_mentor_pm_panel,
67
/client/proc/dementor
78
))
89
GLOBAL_PROTECT(mentor_verbs)

yogstation/code/modules/mentor/mentorpm.dm

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,21 @@
11
//shows a list of clients we could send PMs to, then forwards our choice to cmd_Mentor_pm
22
/client/proc/cmd_mentor_pm_panel()
33
set category = "Mentor"
4-
set name = "Mentor PM"
4+
set name = "Mentor PM Panel"
55

66
if(!is_mentor())
77
to_chat(src, "<font color='red'>Error: Mentor-PM-Panel: Only Mentors and Admins may use this command.</font>", confidential=TRUE)
88
return
99

1010
var/list/client/targets[0]
1111
for(var/client/T)
12-
targets["[T]"] = T
12+
if(T.mob)
13+
targets["[T.mob.name]"] = T
14+
else
15+
targets["[T]"] = T
1316

1417
var/list/sorted = sortList(targets)
15-
var/target = input(src,"To whom shall we send a message?","Mentor PM",null) in sorted|null
18+
var/target = input(src,"To whom shall we send a message?","Mentor PM",null) as null|anything in sorted|null
1619
cmd_mentor_pm(targets[target],null)
1720
SSblackbox.record_feedback("tally", "Mentor_verb", 1, "APM") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
1821

0 commit comments

Comments
 (0)