Disables wrenching on money bot and scanner gate shells when they are locked (#61274)

* Tweaks to wrenching

* Addresses comments

Co-authored-by: Watermelon914 <3052169-Watermelon914@users.noreply.gitlab.com>
This commit is contained in:
Watermelon914
2021-09-07 17:02:02 -04:00
committed by GitHub
co-authored by Watermelon914
parent dc7097ea4a
commit 41301892c9
5 changed files with 63 additions and 3 deletions
+3 -3
View File
@@ -185,7 +185,7 @@
/// Sets whether the shell is locked or not
/datum/component/shell/proc/set_locked(new_value)
locked = new_value
attached_circuit?.locked = locked
attached_circuit?.set_locked(new_value)
/datum/component/shell/proc/on_multitool_act(atom/source, mob/user, obj/item/tool)
@@ -270,7 +270,7 @@
attached_circuit.set_shell(parent_atom)
if(attached_circuit.display_name != "")
parent_atom.name = "[initial(parent_atom.name)] ([attached_circuit.display_name])"
attached_circuit.locked = FALSE
attached_circuit.set_locked(FALSE)
if(shell_flags & SHELL_FLAG_REQUIRE_ANCHOR)
attached_circuit.on = parent_atom.anchored
@@ -296,7 +296,7 @@
for(var/obj/item/circuit_component/to_remove as anything in unremovable_circuit_components)
attached_circuit.remove_component(to_remove)
to_remove.moveToNullspace()
attached_circuit.locked = FALSE
attached_circuit.set_locked(FALSE)
attached_circuit = null
/datum/component/shell/proc/on_atom_usb_cable_try_attach(atom/source, obj/item/usb_cable/usb_cable, mob/user)