mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-18 02:24:11 +01:00
[FIX] Now properly remove/add machines to the RNC console when (un)linked (#26815)
* Now properly remove/add machines to the rdconsole when (un)linked * Remove unused variable --------- Co-authored-by: Adrer <adrermail@gmail.com>
This commit is contained in:
@@ -454,6 +454,7 @@
|
||||
var/user_pass = tgui_input_text(usr, "Please enter network password", "Password Entry")
|
||||
// Check the password
|
||||
if(user_pass == C.network_password)
|
||||
C.mechfabs += UID()
|
||||
network_manager_uid = C.UID()
|
||||
to_chat(usr, "<span class='notice'>Successfully linked to <b>[C.network_name]</b>.</span>")
|
||||
else
|
||||
@@ -536,6 +537,8 @@
|
||||
add_fingerprint(usr)
|
||||
|
||||
/obj/machinery/mecha_part_fabricator/proc/unlink()
|
||||
var/obj/machinery/computer/rnd_network_controller/RNC = locateUID(network_manager_uid)
|
||||
RNC.mechfabs -= UID()
|
||||
network_manager_uid = null
|
||||
SStgui.update_uis(src)
|
||||
|
||||
|
||||
@@ -478,6 +478,7 @@ won't update every console in existence) but it's more of a hassle to do. Also,
|
||||
var/user_pass = input(usr, "Please enter network password", "Password Entry")
|
||||
// Check the password
|
||||
if(user_pass == C.network_password)
|
||||
C.consoles += UID()
|
||||
network_manager_uid = C.UID()
|
||||
to_chat(usr, "<span class='notice'>Successfully linked to <b>[C.network_name]</b>.</span>")
|
||||
else
|
||||
@@ -708,6 +709,8 @@ won't update every console in existence) but it's more of a hassle to do. Also,
|
||||
return TRUE // update uis
|
||||
|
||||
/obj/machinery/computer/rdconsole/proc/unlink()
|
||||
var/obj/machinery/computer/rnd_network_controller/RNC = locateUID(network_manager_uid)
|
||||
RNC.consoles -= UID()
|
||||
network_manager_uid = null
|
||||
SStgui.update_uis(src)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user