Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Status Display QoL. Unify brig timers under status displays. Emissivity and colored text! #10887

Merged
merged 12 commits into from
May 11, 2024
2 changes: 1 addition & 1 deletion _maps/Prefab/Departments.dmm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions _maps/map_files/BoxStation/BoxStation.dmm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions _maps/map_files/CorgStation/CorgStation.dmm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions _maps/map_files/Deltastation/DeltaStation2.dmm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion _maps/map_files/EchoStation/EchoStation.dmm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions _maps/map_files/FlandStation/FlandStation.dmm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion _maps/map_files/KiloStation/KiloStation.dmm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion _maps/map_files/MetaStation/MetaStation.dmm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 9 additions & 9 deletions _maps/map_files/RadStation/RadStation.dmm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion code/__HELPERS/global_lists.dm
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,6 @@ GLOBAL_LIST_INIT(WALLITEMS_INTERIOR, typecacheof(list(
/obj/machinery/computer/security/telescreen,
/obj/machinery/embedded_controller/radio/simple_vent_controller,
/obj/item/storage/secure/safe,
/obj/machinery/door_timer,
/obj/machinery/flasher,
/obj/machinery/keycard_auth,
/obj/structure/mirror,
Expand Down
16 changes: 16 additions & 0 deletions code/_globalvars/lists/flavor_misc.dm
Original file line number Diff line number Diff line change
Expand Up @@ -349,6 +349,22 @@ GLOBAL_LIST_INIT(admiral_messages, list(

GLOBAL_LIST_INIT(junkmail_messages, world.file2list("strings/junkmail.txt"))

// All valid inputs to status display post_status
GLOBAL_LIST_INIT(status_display_approved_pictures, list(
"blank",
"shuttle",
"default",
"biohazard",
"lockdown",
"redalert",
))

// Members of status_display_approved_pictures that are actually states and not alert values
GLOBAL_LIST_INIT(status_display_state_pictures, list(
"blank",
"shuttle",
))

GLOBAL_LIST_INIT(pAI_faces_list, list(
"Angry" = "angry",
"Cat" = "cat",
Expand Down
20 changes: 11 additions & 9 deletions code/game/machinery/computer/communications.dm
Original file line number Diff line number Diff line change
Expand Up @@ -271,11 +271,10 @@
if ("setStatusMessage")
if (!authenticated(usr))
return
var/line_one = reject_bad_text(params["lineOne"] || "", MAX_STATUS_LINE_LENGTH)
var/line_two = reject_bad_text(params["lineTwo"] || "", MAX_STATUS_LINE_LENGTH)
var/line_one = reject_bad_text(params["upperText"] || "", MAX_STATUS_LINE_LENGTH)
var/line_two = reject_bad_text(params["lowerText"] || "", MAX_STATUS_LINE_LENGTH)
message_admins("[ADMIN_LOOKUPFLW(usr)] changed the Status Message to - [line_one], [line_two] - From a Communications Console.")
log_game("[key_name(usr)] changed the Status Message to - [line_one], [line_two] - From a Communications Console.")
post_status("alert", "blank")
post_status("message", line_one, line_two)
last_status_display = list(line_one, line_two)
playsound(src, "terminal_type", 50, FALSE)
Expand All @@ -284,9 +283,12 @@
if (!authenticated(usr))
return
var/picture = params["picture"]
if (!(picture in GLOB.approved_status_pictures))
if (!(picture in GLOB.status_display_approved_pictures))
return
post_status("alert", picture)
if(picture in GLOB.status_display_state_pictures)
post_status(picture)
else
post_status("alert", picture)
playsound(src, "terminal_type", 50, FALSE)
. = TRUE
if ("toggleAuthentication")
Expand Down Expand Up @@ -424,8 +426,8 @@
data["budget"] = bank_account.account_balance
data["shuttles"] = shuttles
if (STATE_CHANGING_STATUS)
data["lineOne"] = last_status_display ? last_status_display[1] : ""
data["lineTwo"] = last_status_display ? last_status_display[2] : ""
data["upperText"] = last_status_display ? last_status_display[1] : ""
data["lowerText"] = last_status_display ? last_status_display[2] : ""

return data

Expand Down Expand Up @@ -511,8 +513,8 @@
var/datum/signal/status_signal = new(list("command" = command))
switch(command)
if("message")
status_signal.data["msg1"] = data1
status_signal.data["msg2"] = data2
status_signal.data["top_text"] = data1
status_signal.data["bottom_text"] = data2
if("alert")
status_signal.data["picture_state"] = data1

Expand Down
Loading
Loading