Files
RikuTheKiller be1f231869 Lock R&D console boards by default (#94114)
## About The Pull Request

This PR makes all R&D console boards that are either printed or sourced
from tech storage start out locked. They can be unlocked by swiping them
with an ID that has research access.

R&D consoles can also be unlocked with an emag, but doing so will break
their comms circuit as well, making all researched nodes broadcast over
public comms. You can still emag the console itself after it's been
constructed without breaking it in any way, while also silencing
announcements instead. (that's definitely a noob trap, but it's out of
scope for this PR)

The reason why the tech storage board is locked as well is because the
goal of this PR is to stop engineers from making R&D consoles, and
engineers have access to tech storage. Leaving the board unlocked and
moving it to secure tech storage would make engineers break in there
every shift.

The changelog basically has a FAQ for "Okay, so what do I do instead?",
because I know people will be confused about what route they're intended
to take when science closes their desk shutters for the umpteenth time
this week.
## Why It's Good For The Game

Engineering has a habit of making an R&D console every round to bypass
having to ask science or a head of staff to research things. Locking the
consoles at least makes engineers consider asking science to do
science's job.

Note that this doesn't solve the issue entirely, it just removes the
easiest and most convenient way of bypassing science. Engineers can
still break into R&D extremely easily using their wire knowledge, and do
so regularly.

More importantly though, this might shine some light on the fact that
heads of department like the CE have remote access to the research
network via their PDAs. This means engineers can ask the CE to research
things for them.

Asking people with access to the research network to research things is
a lot better for roleplay and immersion than having engineering
construct R&D consoles every shift.

## Changelog
🆑
balance: R&D console boards sourced from printing or tech storage are
now locked by default. It's recommended to ask your respective head of
department or the science department to complete research for you. Heads
of department can remotely access the research network using their PDAs.
/🆑
2025-12-05 19:12:22 -05:00

88 lines
3.0 KiB
Plaintext

/obj/machinery/computer/rdservercontrol
name = "R&D Server Controller"
desc = "Manages access to research databases and consoles."
icon_screen = "rdcomp"
icon_keyboard = "rd_key"
circuit = /obj/item/circuitboard/computer/rdservercontrol
req_access = list(ACCESS_RD)
///Connected techweb node the server is connected to.
var/datum/techweb/stored_research
/obj/machinery/computer/rdservercontrol/post_machine_initialize()
. = ..()
if(!CONFIG_GET(flag/no_default_techweb_link) && !stored_research)
CONNECT_TO_RND_SERVER_ROUNDSTART(stored_research, src)
/obj/machinery/computer/rdservercontrol/multitool_act(mob/living/user, obj/item/multitool/tool)
if(!QDELETED(tool.buffer) && istype(tool.buffer, /datum/techweb))
stored_research = tool.buffer
balloon_alert(user, "techweb connected")
return TRUE
/obj/machinery/computer/rdservercontrol/emag_act(mob/user, obj/item/card/emag/emag_card)
if(obj_flags & EMAGGED)
return FALSE
obj_flags |= EMAGGED
playsound(src, SFX_SPARKS, 75, TRUE, SHORT_RANGE_SOUND_EXTRARANGE)
balloon_alert(user, "console emagged")
return TRUE
/obj/machinery/computer/rdservercontrol/ui_interact(mob/user, datum/tgui/ui)
. = ..()
ui = SStgui.try_update_ui(user, src, ui)
if(!ui)
ui = new(user, src, "ServerControl", name)
ui.open()
/obj/machinery/computer/rdservercontrol/ui_data(mob/user)
var/list/data = list()
data["server_connected"] = !!stored_research
if(stored_research)
data["logs"] += stored_research.research_logs
for(var/obj/machinery/rnd/server/server as anything in stored_research.techweb_servers)
data["servers"] += list(list(
"server_name" = server,
"server_details" = server.get_status_text(),
"server_disabled" = server.research_disabled,
"server_ref" = REF(server),
))
for(var/obj/machinery/computer/rdconsole/console as anything in stored_research.consoles_accessing)
var/obj/item/circuitboard/computer/rdconsole/console_board = console.circuit
data["consoles"] += list(list(
"console_name" = console,
"console_location" = get_area(console),
"console_locked" = console_board.locked,
"console_ref" = REF(console),
))
return data
/obj/machinery/computer/rdservercontrol/ui_act(action, list/params, datum/tgui/ui, datum/ui_state/state)
. = ..()
if(.)
return TRUE
if(!allowed(usr) && !(obj_flags & EMAGGED))
balloon_alert(usr, "access denied!")
playsound(src, 'sound/machines/click.ogg', 20, TRUE)
return TRUE
switch(action)
if("lockdown_server")
var/obj/machinery/rnd/server/server_selected = locate(params["selected_server"]) in stored_research.techweb_servers
if(!server_selected)
return FALSE
server_selected.toggle_disable(usr)
return TRUE
if("lock_console")
var/obj/machinery/computer/rdconsole/console_selected = locate(params["selected_console"]) in stored_research.consoles_accessing
var/obj/item/circuitboard/computer/rdconsole/console_board = console_selected.circuit
if(!console_selected)
return FALSE
console_board.locked = !console_board.locked
return TRUE