Adds true observing -- letting you see what your target sees (#24855)

* bring it back now y'all

* adds a bunch of other changes

* pretty much works at this point

* grep

* Fixes some bugs, still chasing some down

* Add observers to recursive mob check, ensuring they can see messages from their orbitted atom

* tidy some things up

* resolve

* remove unnecessary checks

* Address todos, minor cleanups

* oh dear

* initial testing

* Fix some vulnerabilities (oops)

* Fix some other bugs from testing

* ci fixes

* Add some contingencies against clicking things you shouldn't

* fix some noted bugs

* Add observe to admin jump, improve messaging

* add a few more fixes that should mostly address some runtimes

* oh this wasn't really great

* one last thing

* Fix suit inventory problem

* Remove merge artifact

* Add some missing parens

* Prevents you from observing other ghosts, and should fix the getting stuck outside of your body issue.

* we love testing

* adds to player panel

* Fix more bugs with observers getting stuck outside of their body

* cleans up player panel, verb offerings

* shit

* Update code/_onclick/hud/alert.dm

welp

Co-authored-by: GDN <96800819+GDNgit@users.noreply.github.com>
Signed-off-by: Luc <89928798+lewcc@users.noreply.github.com>

* Fixes some targeting issues

* Fixes targeting on aobserve

* Fix some weird storage bugs

* clean up some doulbed up follow links

* Update code/modules/admin/player_panel.dm

Signed-off-by: Luc <89928798+lewcc@users.noreply.github.com>

* Adds some checks for ghost observe

* Remove mentor debug log

* ahhhhhhhhh that'll do it

* Cleans up some additional checks that were not quite what they should have been

* better logging, too

* mochi review

* one more thing

* Gets robot huds mostly working

* hopefully fix folks not getting observe

* Fix order of operations causing a runtime on qdeleting

* Remove some unnecessary stack traces

* Apply suggestions from code review

Co-authored-by: 1080pCat <96908085+1080pCat@users.noreply.github.com>
Signed-off-by: Luc <89928798+lewcc@users.noreply.github.com>

* Fix bug with items in your inventory disappearing on changing HUD modes

* Fix some bugs with the observe verbs

* possibly fix nullspace issues

* funny review

* missed one

---------

Signed-off-by: Luc <89928798+lewcc@users.noreply.github.com>
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: GDN <96800819+GDNgit@users.noreply.github.com>
Co-authored-by: S34N <12197162+S34NW@users.noreply.github.com>
Co-authored-by: 1080pCat <96908085+1080pCat@users.noreply.github.com>
This commit is contained in:
Luc
2024-05-23 11:46:43 -04:00
committed by GitHub
parent 7bf45dce58
commit 23ad8a48fa
38 changed files with 1108 additions and 384 deletions
+5 -4
View File
@@ -178,6 +178,7 @@
var/ping_link = check_rights(R_ADMIN, 0, mob) ? "(<a href='byond://?src=[pm_tracker.UID()];ping=[C.key]'>PING</a>)" : ""
var/ticket_link
var/alert_link = check_rights(R_ADMIN, FALSE, mob) ? "(<a href='byond://?src=[pm_tracker.UID()];adminalert=[C.mob.UID()]'>ALERT</a>)" : ""
var/observe_link = check_rights(R_MENTOR, FALSE, mob) ? "([ADMIN_OBS(C, "OBS")])" : ""
if(ticket_id != -1)
if(message_type == MESSAGE_TYPE_MENTORPM)
ticket_link = "(<a href='byond://?_src_=holder;openticket=[ticket_id];is_mhelp=1'>TICKET</a>)"
@@ -190,7 +191,7 @@
receive_window_link = ticket_link
else if(message_type == MESSAGE_TYPE_ADMINPM && check_rights(R_ADMIN, 0, C.mob))
receive_window_link = ticket_link
receive_message = "<span class='[receive_span]'>[type] from-<b>[receive_pm_type] [C.holder ? key_name(src, TRUE, type, ticket_id = ticket_id) : key_name_hidden(src, TRUE, type, ticket_id = ticket_id)]</b>:<br><br>[emoji_msg][C.holder ? "<br>[ping_link] [receive_window_link] [alert_link]" : ""]</span>"
receive_message = "<span class='[receive_span]'>[type] from-<b>[receive_pm_type] [C.holder ? key_name(src, TRUE, type, ticket_id = ticket_id) : key_name_hidden(src, TRUE, type, ticket_id = ticket_id)]</b>:<br><br>[emoji_msg][C.holder ? "<br>[ping_link] [receive_window_link] [alert_link] [observe_link]" : ""]</span>"
if(message_type == MESSAGE_TYPE_MENTORPM)
receive_message = chat_box_mhelp(receive_message)
else
@@ -202,7 +203,7 @@
send_window_link = ticket_link
else if(message_type == MESSAGE_TYPE_ADMINPM && check_rights(R_ADMIN, 0, mob))
send_window_link = ticket_link
var/send_message = "<span class='[send_span]'>[send_pm_type][type] to-<b>[holder ? key_name(C, TRUE, type, ticket_id = ticket_id) : key_name_hidden(C, TRUE, type, ticket_id = ticket_id)]</b>:<br><br>[emoji_msg]</span><br>[ping_link] [send_window_link] [alert_link]"
var/send_message = "<span class='[send_span]'>[send_pm_type][type] to-<b>[holder ? key_name(C, TRUE, type, ticket_id = ticket_id) : key_name_hidden(C, TRUE, type, ticket_id = ticket_id)]</b>:<br><br>[emoji_msg]</span><br>[ping_link] [send_window_link] [alert_link] [observe_link]"
if(message_type == MESSAGE_TYPE_MENTORPM)
send_message = chat_box_mhelp(send_message)
else
@@ -211,9 +212,9 @@
var/third_party_message
if(message_type == MESSAGE_TYPE_MENTORPM)
third_party_message = chat_box_mhelp("<span class='mentorhelp'>[type]: [key_name(src, TRUE, type, ticket_id = ticket_id)]-&gt;[key_name(C, TRUE, type, ticket_id = ticket_id)]:<br><br>[emoji_msg]<br>[ping_link] [ticket_link] [alert_link]</span>")
third_party_message = chat_box_mhelp("<span class='mentorhelp'>[type]: [key_name(src, TRUE, type, ticket_id = ticket_id)]-&gt;[key_name(C, TRUE, type, ticket_id = ticket_id)]:<br><br>[emoji_msg]<br>[ping_link] [ticket_link] [alert_link] [observe_link]</span>")
else
third_party_message = chat_box_ahelp("<span class='adminhelp'>[type]: [key_name(src, TRUE, type, ticket_id = ticket_id)]-&gt;[key_name(C, TRUE, type, ticket_id = ticket_id)]:<br><br>[emoji_msg]<br>[ping_link] [ticket_link] [alert_link]</span>")
third_party_message = chat_box_ahelp("<span class='adminhelp'>[type]: [key_name(src, TRUE, type, ticket_id = ticket_id)]-&gt;[key_name(C, TRUE, type, ticket_id = ticket_id)]:<br><br>[emoji_msg]<br>[ping_link] [ticket_link] [alert_link] [observe_link]</span>")
//play the recieving admin the adminhelp sound (if they have them enabled)
//non-admins always hear the sound, as they cannot toggle it