mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-01-29 18:40:42 +00:00
## About The Pull Request This PR started with the idea of adding support for map feedback threads, which I added to the roundend report, escape menu, and stat panel. To do this though I had to make pretty annoying changes to the stat panel and had to touch every single time something to the stat panel was added, so since we now have a way to have links in the stat panel I thought of taking full advantage of it and add some QOL. AIs can now track their borgs by clicking their status on the stat panel https://github.com/user-attachments/assets/1789dc46-5d12-48e9-bb8d-d3278aa19639 With Melbert's comment, I added another stat panel entry that directs you to the Webmap page, which currently seems to be a little messed up (https://github.com/AffectedArc07/SS13WebMap/issues/41 & https://github.com/AffectedArc07/SS13WebMap/issues/42) but if they get fixed this would be a swag asf feature ##### Code bounty for Ezel/Improvedname ## Why It's Good For The Game Feedback threads was a suggestion from a player and is fully in control of admins as an optional thing, and while we still have stat panel I think it's nice to be able to take advantage of its features. ## Changelog 🆑 admin: Admins can now link a URL for maps, used to give feedback on said maps. Accessible through the roundend report, escape menu, and stat panel. qol: AIs can track their borgs by clicking on them in the stat panel. qol: You can now directly go to the webmap of maps from the stat panel (assuming it's set in config). /🆑
44 lines
1.3 KiB
Plaintext
44 lines
1.3 KiB
Plaintext
// This doesn't instantiate right away, since we rely on other GLOBs
|
|
GLOBAL_DATUM(escape_menu_details, /atom/movable/screen/escape_menu/details)
|
|
|
|
/// Provides a singleton for the escape menu details screen.
|
|
/proc/give_escape_menu_details()
|
|
if (isnull(GLOB.escape_menu_details))
|
|
GLOB.escape_menu_details = new
|
|
|
|
return GLOB.escape_menu_details
|
|
|
|
/atom/movable/screen/escape_menu/details
|
|
screen_loc = "EAST:-180,NORTH:-34"
|
|
maptext_height = 100
|
|
maptext_width = 200
|
|
|
|
/atom/movable/screen/escape_menu/details/Initialize(mapload, datum/hud/hud_owner)
|
|
. = ..()
|
|
|
|
update_text()
|
|
START_PROCESSING(SSescape_menu, src)
|
|
|
|
/atom/movable/screen/escape_menu/details/Destroy()
|
|
if (GLOB.escape_menu_details == src)
|
|
stack_trace("Something tried to delete the escape menu details screen")
|
|
return QDEL_HINT_LETMELIVE
|
|
|
|
STOP_PROCESSING(SSescape_menu, src)
|
|
return ..()
|
|
|
|
/atom/movable/screen/escape_menu/details/process(seconds_per_tick)
|
|
update_text()
|
|
|
|
/atom/movable/screen/escape_menu/details/proc/update_text()
|
|
var/new_maptext = {"
|
|
<span style='text-align: right; line-height: 0.7'>
|
|
Round ID: [GLOB.round_id || "Unset"]<br />
|
|
Round Time: [ROUND_TIME()]<br />
|
|
Map: [SSmapping.current_map.return_map_name(webmap_included = TRUE) || "Loading..."]<br />
|
|
Time Dilation: [round(SStime_track.time_dilation_current,1)]%<br />
|
|
</span>
|
|
"}
|
|
|
|
maptext = MAPTEXT(new_maptext)
|