From 1b05577bdf434fe614c138c7ab6fad624372efaa Mon Sep 17 00:00:00 2001 From: Batrachophreno Date: Mon, 8 Jun 2026 06:45:31 -0400 Subject: [PATCH] TGUI Hotfixes, Oh God Am I The TGUI Guy Now Edition (#22648) changes: - bugfix: "Restores the Modular Computer access cable header button for connecting to IPCs and machinery." - bugfix: "Fixes display issues in the Robotics interface's elements." - bugfix: "Fixes in-chat feedback text provided by the Cyborg Analyzer (organ name and status now both inline)." - bugfix: "Crew Manifest PDA app now filters out off-ship personnel." - bugfix: "Fixes Autolathe TGUI appending search- and category- filtered recipes instead of recomputing the list with those filters." - bugfix: "Fixes runtime when ghost opens dedicated camera console UI." - code_imp: "Update some defs referencing 'supply' department to 'operations'." - refactor: "Standardizes all interface search bars to use the native 'SearchBar' component." - refactor: "AtmosAlarmControl interface now correctly auto-sorts alarms by alert status." --- code/controllers/subsystems/radio.dm | 4 +- .../items/devices/radio/_radio_defines.dm | 4 +- .../items/devices/radio/encryptionkey.dm | 12 +- .../structures/machinery/computer/camera.dm | 11 +- .../living/silicon/ai/ai_remote_control.dm | 2 +- .../mob/living/silicon/robot/analyzer.dm | 11 +- .../mob/living/silicon/robot/robot_modules.dm | 12 +- .../file_system/programs/research/robotics.dm | 53 ++-- .../file_system/programs/security/camera.dm | 11 +- code/modules/tgui/modules/ipc_diagnostic.dm | 3 + code/stylesheet.dm | 3 +- html/changelogs/Bat-TGUIHotfixes5.yml | 12 + .../tgui-panel/styles/tgchat/chat-dark.scss | 2 +- .../tgui-panel/styles/tgchat/chat-light.scss | 2 +- tgui/packages/tgui-say/styles/colors.scss | 76 +++--- tgui/packages/tgui/interfaces/ATM.tsx | 2 +- .../tgui/interfaces/AtmosAlarmControl.tsx | 39 +-- tgui/packages/tgui/interfaces/Autolathe.tsx | 247 +++++++++--------- .../tgui/interfaces/CameraMonitoring.tsx | 13 +- tgui/packages/tgui/interfaces/CargoOrder.tsx | 10 +- tgui/packages/tgui/interfaces/ChatClient.tsx | 23 +- tgui/packages/tgui/interfaces/ChemCodex.tsx | 13 +- .../packages/tgui/interfaces/CookingCodex.tsx | 13 +- tgui/packages/tgui/interfaces/FollowMenu.tsx | 33 +-- tgui/packages/tgui/interfaces/FusionCodex.tsx | 13 +- .../packages/tgui/interfaces/GhostSpawner.tsx | 12 +- tgui/packages/tgui/interfaces/Holopad.tsx | 55 ++-- .../tgui/interfaces/IPCDiagnostics.tsx | 2 +- .../tgui/interfaces/LibraryComputer.tsx | 8 +- .../ListInputWindow/ListInputModal.tsx | 11 +- tgui/packages/tgui/interfaces/PlayerPanel.tsx | 13 +- tgui/packages/tgui/interfaces/PsionicShop.tsx | 12 +- tgui/packages/tgui/interfaces/QuikPay.tsx | 9 +- tgui/packages/tgui/interfaces/RCON.tsx | 20 +- tgui/packages/tgui/interfaces/Records.tsx | 40 +-- tgui/packages/tgui/interfaces/SmartFridge.tsx | 25 +- tgui/packages/tgui/interfaces/Uplink.tsx | 8 +- tgui/packages/tgui/interfaces/Vending.tsx | 41 +-- .../interfaces/common/ManifestSection.tsx | 18 +- .../tgui/interfaces/common/SearchBar.tsx | 4 + tgui/packages/tgui/layouts/NtosWindow.tsx | 13 + .../tgui/styles/interfaces/Radio.scss | 2 +- 42 files changed, 494 insertions(+), 423 deletions(-) create mode 100644 html/changelogs/Bat-TGUIHotfixes5.yml diff --git a/code/controllers/subsystems/radio.dm b/code/controllers/subsystems/radio.dm index f62d53a49bf..0e83f3f93ba 100644 --- a/code/controllers/subsystems/radio.dm +++ b/code/controllers/subsystems/radio.dm @@ -199,8 +199,8 @@ SUBSYSTEM_DEF(radio) return "sciradio" if (MED_FREQ,MED_I_FREQ) return"medradio" - if (SUP_FREQ) // cargo - return "supradio" + if (SUP_FREQ) // operations + return "opsradio" if (SRV_FREQ) // service return "srvradio" if (ENT_FREQ) //entertainment diff --git a/code/game/objects/items/devices/radio/_radio_defines.dm b/code/game/objects/items/devices/radio/_radio_defines.dm index d8ac338f16b..dbb5002b17a 100644 --- a/code/game/objects/items/devices/radio/_radio_defines.dm +++ b/code/game/objects/items/devices/radio/_radio_defines.dm @@ -6,7 +6,7 @@ #define CHANNEL_MEDICAL "Medical" #define CHANNEL_ENGINEERING "Engineering" #define CHANNEL_SECURITY "Security" -#define CHANNEL_SUPPLY "Operations" +#define CHANNEL_OPERATIONS "Operations" #define CHANNEL_SERVICE "Service" #define CHANNEL_AI_PRIVATE "AI Private" #define CHANNEL_PENAL "Penal" @@ -32,7 +32,7 @@ var/global/list/ALL_RADIO_CHANNELS = list( CHANNEL_MEDICAL = TRUE, CHANNEL_ENGINEERING = TRUE, CHANNEL_SECURITY = TRUE, - CHANNEL_SUPPLY = TRUE, + CHANNEL_OPERATIONS = TRUE, CHANNEL_SERVICE = TRUE, CHANNEL_AI_PRIVATE = TRUE, CHANNEL_PENAL = TRUE, diff --git a/code/game/objects/items/devices/radio/encryptionkey.dm b/code/game/objects/items/devices/radio/encryptionkey.dm index d55258aa19b..0305ff384b8 100644 --- a/code/game/objects/items/devices/radio/encryptionkey.dm +++ b/code/game/objects/items/devices/radio/encryptionkey.dm @@ -170,13 +170,13 @@ /obj/item/encryptionkey/heads/captain name = "captain's encryption key" icon_state = "cap_cypherkey" - channels = list(CHANNEL_COMMAND = TRUE, CHANNEL_SECURITY = TRUE, CHANNEL_PENAL = TRUE, CHANNEL_ENGINEERING = TRUE, CHANNEL_SCIENCE = TRUE, CHANNEL_MEDICAL = TRUE, CHANNEL_SUPPLY = TRUE, CHANNEL_SERVICE = TRUE, CHANNEL_HAILING = TRUE) + channels = list(CHANNEL_COMMAND = TRUE, CHANNEL_SECURITY = TRUE, CHANNEL_PENAL = TRUE, CHANNEL_ENGINEERING = TRUE, CHANNEL_SCIENCE = TRUE, CHANNEL_MEDICAL = TRUE, CHANNEL_OPERATIONS = TRUE, CHANNEL_SERVICE = TRUE, CHANNEL_HAILING = TRUE) /obj/item/encryptionkey/heads/ai_integrated name = "ai integrated encryption key" desc = "Integrated encryption key" icon_state = "cap_cypherkey" - channels = list(CHANNEL_COMMAND = TRUE, CHANNEL_SECURITY = TRUE, CHANNEL_PENAL = TRUE, CHANNEL_ENGINEERING = TRUE, CHANNEL_SCIENCE = TRUE, CHANNEL_MEDICAL = TRUE, CHANNEL_SUPPLY = TRUE, CHANNEL_SERVICE = TRUE, CHANNEL_AI_PRIVATE = TRUE, CHANNEL_HAILING = TRUE) + channels = list(CHANNEL_COMMAND = TRUE, CHANNEL_SECURITY = TRUE, CHANNEL_PENAL = TRUE, CHANNEL_ENGINEERING = TRUE, CHANNEL_SCIENCE = TRUE, CHANNEL_MEDICAL = TRUE, CHANNEL_OPERATIONS = TRUE, CHANNEL_SERVICE = TRUE, CHANNEL_AI_PRIVATE = TRUE, CHANNEL_HAILING = TRUE) /obj/item/encryptionkey/heads/rd name = "research director's encryption key" @@ -206,12 +206,12 @@ /obj/item/encryptionkey/headset_cargo name = "operations radio encryption key" icon_state = "cargo_cypherkey" - channels = list(CHANNEL_SUPPLY = TRUE, CHANNEL_HAILING = TRUE) + channels = list(CHANNEL_OPERATIONS = TRUE, CHANNEL_HAILING = TRUE) /obj/item/encryptionkey/headset_operations_manager name = "operations manager radio encryption key" icon_state = "cargo_cypherkey" - channels = list(CHANNEL_COMMAND = TRUE, CHANNEL_SUPPLY = TRUE, CHANNEL_HAILING = TRUE) + channels = list(CHANNEL_COMMAND = TRUE, CHANNEL_OPERATIONS = TRUE, CHANNEL_HAILING = TRUE) /obj/item/encryptionkey/headset_service name = "service radio encryption key" @@ -220,7 +220,7 @@ /obj/item/encryptionkey/ert name = "\improper ERT radio encryption key" - channels = list(CHANNEL_RESPONSE_TEAM = TRUE, CHANNEL_SCIENCE = TRUE, CHANNEL_COMMAND = TRUE, CHANNEL_MEDICAL = TRUE, CHANNEL_ENGINEERING = TRUE, CHANNEL_SECURITY = TRUE, CHANNEL_SUPPLY = TRUE, CHANNEL_SERVICE = TRUE, CHANNEL_HAILING = TRUE) + channels = list(CHANNEL_RESPONSE_TEAM = TRUE, CHANNEL_SCIENCE = TRUE, CHANNEL_COMMAND = TRUE, CHANNEL_MEDICAL = TRUE, CHANNEL_ENGINEERING = TRUE, CHANNEL_SECURITY = TRUE, CHANNEL_OPERATIONS = TRUE, CHANNEL_SERVICE = TRUE, CHANNEL_HAILING = TRUE) /obj/item/encryptionkey/onlyert name = "\improper ERT radio encryption key" @@ -254,7 +254,7 @@ /obj/item/encryptionkey/cargo_spare name = "spare operations radio encryption key" - additional_channels = list(CHANNEL_SUPPLY = TRUE) + additional_channels = list(CHANNEL_OPERATIONS = TRUE) /obj/item/encryptionkey/service_spare name = "spare service radio encryption key" diff --git a/code/game/objects/structures/machinery/computer/camera.dm b/code/game/objects/structures/machinery/computer/camera.dm index f473c778658..cf7bfc62896 100644 --- a/code/game/objects/structures/machinery/computer/camera.dm +++ b/code/game/objects/structures/machinery/computer/camera.dm @@ -136,11 +136,18 @@ if(!istype(user)) return 0 - var/obj/item/card/id/I = user.GetIdCard() + var/I = user.GetIdCard() if(!I) return 0 - if(access in I.access) + var/list/access_list + if(islist(I)) + access_list = I + else if(istype(I, /obj/item)) + var/obj/item/item = I + access_list = item.GetAccess() + + if(access in access_list) return 1 return 0 diff --git a/code/modules/mob/living/silicon/ai/ai_remote_control.dm b/code/modules/mob/living/silicon/ai/ai_remote_control.dm index 2e6a95f35e8..668ece26311 100644 --- a/code/modules/mob/living/silicon/ai/ai_remote_control.dm +++ b/code/modules/mob/living/silicon/ai/ai_remote_control.dm @@ -1,6 +1,6 @@ /obj/item/robot_module/aicontrol name = "ai controlled robot module" - channels = list(CHANNEL_COMMAND = TRUE, CHANNEL_SCIENCE = TRUE, CHANNEL_MEDICAL = TRUE, CHANNEL_ENGINEERING = TRUE, CHANNEL_SECURITY = TRUE, CHANNEL_SUPPLY = TRUE, CHANNEL_SERVICE = TRUE, CHANNEL_AI_PRIVATE = TRUE, CHANNEL_HAILING = TRUE) + channels = list(CHANNEL_COMMAND = TRUE, CHANNEL_SCIENCE = TRUE, CHANNEL_MEDICAL = TRUE, CHANNEL_ENGINEERING = TRUE, CHANNEL_SECURITY = TRUE, CHANNEL_OPERATIONS = TRUE, CHANNEL_SERVICE = TRUE, CHANNEL_AI_PRIVATE = TRUE, CHANNEL_HAILING = TRUE) networks = list(NETWORK_COMMAND) languages = list( LANGUAGE_SOL_COMMON = TRUE, diff --git a/code/modules/mob/living/silicon/robot/analyzer.dm b/code/modules/mob/living/silicon/robot/analyzer.dm index 786ca5bee22..272001219ed 100644 --- a/code/modules/mob/living/silicon/robot/analyzer.dm +++ b/code/modules/mob/living/silicon/robot/analyzer.dm @@ -102,17 +102,16 @@ continue organ_found = TRUE var/found_damage = FALSE - to_chat(user, SPAN_NOTICE(SPAN_BOLD("[O.name]"))) - if(O.damage) - to_chat(user, SPAN_WARNING("Core damage detected.")) - found_damage = TRUE if(istype(O, /obj/item/organ/internal/machine)) var/obj/item/organ/internal/machine/machine_organ = O if(machine_organ.get_integrity() < 100) - to_chat(user, SPAN_WARNING("[machine_organ.name]: Integrity damage detected.")) + to_chat(user, "[machine_organ.name]: Integrity damage detected.") found_damage = TRUE + else if(O.damage) + to_chat(user, SPAN_WARNING("[O.name]: Core damage detected.")) + found_damage = TRUE if(!found_damage) - to_chat(user, SPAN_NOTICE("No damage detected.")) + to_chat(user, SPAN_GOOD("[O.name]: No damage detected.")) if(!organ_found) to_chat(user, SPAN_NOTICE("No prosthetics located.")) diff --git a/code/modules/mob/living/silicon/robot/robot_modules.dm b/code/modules/mob/living/silicon/robot/robot_modules.dm index 64f32b1e707..b1e0aff3bfe 100644 --- a/code/modules/mob/living/silicon/robot/robot_modules.dm +++ b/code/modules/mob/living/silicon/robot/robot_modules.dm @@ -701,7 +701,7 @@ GLOBAL_LIST_INIT(robot_modules, list( /obj/item/robot_module/service/clerical name = "clerical robot module" - channels = list(CHANNEL_SUPPLY = TRUE, CHANNEL_COMMAND = TRUE) + channels = list(CHANNEL_OPERATIONS = TRUE, CHANNEL_COMMAND = TRUE) networks = list(NETWORK_MINE) specialized_access_types = list(/datum/job/janitor) // Janitor is a nice general access without specifics @@ -727,7 +727,7 @@ GLOBAL_LIST_INIT(robot_modules, list( /obj/item/robot_module/miner name = "miner robot module" - channels = list(CHANNEL_SUPPLY = TRUE, CHANNEL_HAILING = TRUE) + channels = list(CHANNEL_OPERATIONS = TRUE, CHANNEL_HAILING = TRUE) networks = list(NETWORK_MINE) sprites = list( "Basic" = list(ROBOT_CHASSIS = "robot_mine", ROBOT_PANEL = "robot", ROBOT_EYES = "robot"), @@ -794,7 +794,7 @@ GLOBAL_LIST_INIT(robot_modules, list( name = "research module" channels = list( CHANNEL_SCIENCE = TRUE, - CHANNEL_SUPPLY = TRUE + CHANNEL_OPERATIONS = TRUE ) networks = list(NETWORK_RESEARCH) sprites = list( @@ -1080,7 +1080,7 @@ GLOBAL_LIST_INIT(robot_modules, list( /obj/item/robot_module/mining_drone name = "mining drone module" no_slip = TRUE - channels = list(CHANNEL_SUPPLY = TRUE) + channels = list(CHANNEL_OPERATIONS = TRUE) networks = list(NETWORK_MINE) all_access = TRUE @@ -1164,7 +1164,7 @@ GLOBAL_LIST_INIT(robot_modules, list( ) channels = list( CHANNEL_SERVICE = TRUE, - CHANNEL_SUPPLY = TRUE, + CHANNEL_OPERATIONS = TRUE, CHANNEL_SCIENCE = TRUE, CHANNEL_SECURITY = TRUE, CHANNEL_ENGINEERING = TRUE, @@ -1314,7 +1314,7 @@ GLOBAL_LIST_INIT(robot_modules, list( ) channels = list( CHANNEL_SERVICE = TRUE, - CHANNEL_SUPPLY = TRUE, + CHANNEL_OPERATIONS = TRUE, CHANNEL_SCIENCE = TRUE, CHANNEL_SECURITY = TRUE, CHANNEL_ENGINEERING = TRUE, diff --git a/code/modules/modular_computers/file_system/programs/research/robotics.dm b/code/modules/modular_computers/file_system/programs/research/robotics.dm index a664dc84d83..9aab7fc9f1c 100644 --- a/code/modules/modular_computers/file_system/programs/research/robotics.dm +++ b/code/modules/modular_computers/file_system/programs/research/robotics.dm @@ -13,6 +13,20 @@ /// The diagnostics module associated with this program. var/datum/tgui_module/ipc_diagnostic/diagnostic +/datum/computer_file/program/robotics/proc/get_connected_ipc() + if(!computer.access_cable_dongle?.access_cable) + return + + var/obj/item/organ/internal/machine/access_port/port = computer.access_cable_dongle.access_cable.target + if(!istype(port)) + return + + var/mob/living/carbon/human/ipc = port.owner + if(!isipc(ipc)) + return + + return ipc + /datum/computer_file/program/robotics/ui_act(action, list/params, datum/tgui/ui, datum/ui_state/state) . = ..() if(!ishuman(ui.user)) @@ -20,35 +34,28 @@ var/mob/living/carbon/human/user = ui.user if(action == "run_diagnostics") - if(computer.access_cable_dongle && computer.access_cable_dongle.access_cable) - var/mob/living/carbon/human/synthetic = computer.access_cable_dongle.access_cable.target - if(istype(user) && istype(synthetic)) - ui.user.visible_message(SPAN_NOTICE("[user] begins running a diagnostic scan...")) - if(do_after(user, 3 SECONDS)) - diagnostic = new(user, synthetic) - return TRUE + var/mob/living/carbon/human/synthetic = get_connected_ipc() + if(istype(synthetic)) + ui.user.visible_message(SPAN_NOTICE("[user] begins running a diagnostic scan...")) + if(do_after(user, 3 SECONDS)) + diagnostic = new(user, synthetic) + return TRUE if(action == "open_diagnostic") - if(computer.access_cable_dongle && computer.access_cable_dongle.access_cable) + var/mob/living/carbon/human/synthetic = get_connected_ipc() + if(istype(diagnostic)) + if(diagnostic.patient != synthetic) + to_chat(user, SPAN_WARNING("This diagnostic is no longer valid and has been deleted.")) + QDEL_NULL(diagnostic) + return TRUE - if(istype(diagnostic)) - if(diagnostic.patient != computer.access_cable_dongle.access_cable.target) - to_chat(user, SPAN_WARNING("This diagnostic is no longer valid and has been deleted.")) - qdel(diagnostic) - return TRUE - - var/mob/living/carbon/human/synthetic = computer.access_cable_dongle.access_cable.target - if(istype(user) && istype(synthetic)) - diagnostic.ui_interact(user) - return TRUE + if(istype(synthetic)) + diagnostic.ui_interact(user) + return TRUE /datum/computer_file/program/robotics/ui_data(mob/user) var/list/data = list() - var/mob/living/carbon/human/ipc - if(computer.access_cable_dongle && computer.access_cable_dongle.access_cable) - var/obj/item/organ/internal/machine/access_port/port = computer.access_cable_dongle.access_cable.target - if(istype(port)) - ipc = port.owner + var/mob/living/carbon/human/ipc = get_connected_ipc() if(isipc(ipc)) var/datum/species/machine/machine_species = ipc.species // need to manually set to ipc species because of machine_ui_theme diff --git a/code/modules/modular_computers/file_system/programs/security/camera.dm b/code/modules/modular_computers/file_system/programs/security/camera.dm index ee2a08d1700..d68ba5d039b 100644 --- a/code/modules/modular_computers/file_system/programs/security/camera.dm +++ b/code/modules/modular_computers/file_system/programs/security/camera.dm @@ -92,11 +92,18 @@ if(!istype(user)) return 0 - var/obj/item/card/id/I = user.GetIdCard() + var/I = user.GetIdCard() if(!I) return 0 - if(access in I.access) + var/list/access_list + if(islist(I)) + access_list = I + else if(istype(I, /obj/item)) + var/obj/item/item = I + access_list = item.GetAccess() + + if(access in access_list) return 1 return 0 diff --git a/code/modules/tgui/modules/ipc_diagnostic.dm b/code/modules/tgui/modules/ipc_diagnostic.dm index 38a10f72ddc..6b1cf44c67e 100644 --- a/code/modules/tgui/modules/ipc_diagnostic.dm +++ b/code/modules/tgui/modules/ipc_diagnostic.dm @@ -25,6 +25,9 @@ var/obj/item/organ/internal/machine/internal_diagnostics/diagnostics = ipc.internal_organs_by_name[BP_DIAGNOSTICS_SUITE] if(!istype(diagnostics)) data["broken"] = TRUE + data["patient_name"] = ipc.real_name + data["machine_ui_theme"] = machine_species.machine_ui_theme + return data data["patient_name"] = ipc.real_name data["broken"] = diagnostics.is_broken() diff --git a/code/stylesheet.dm b/code/stylesheet.dm index 9958c4cfba9..d1821d0a74c 100644 --- a/code/stylesheet.dm +++ b/code/stylesheet.dm @@ -4,6 +4,7 @@ // If you modify this file you ALSO need to modify tgui/packages/tgui-panel/styles/tgchat/chat-light.scss and chat-dark.scss // BUT you have to use PX font sizes with are on a x8 scale of these font sizes +// For radio channel colors, ensure you update the 'say' window colors in 'tgui/packages/tgui-say/styles/colors.scss' as well. // Sample font-size: DM: 8 CSS: 64px /client/script = {"