Make USB cables attached to locked circuits unable to be modified (#63084)

Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
This commit is contained in:
RandomGamer123
2021-12-05 06:02:09 -05:00
committed by GitHub
parent fe5fcc164b
commit 06a00e4e38
2 changed files with 8 additions and 0 deletions

View File

@@ -355,6 +355,10 @@
source.balloon_alert(user, "no circuit inside")
return COMSIG_CANCEL_USB_CABLE_ATTACK
if(attached_circuit.locked)
source.balloon_alert(user, "circuit is locked!")
return COMSIG_CANCEL_USB_CABLE_ATTACK
usb_cable.attached_circuit = attached_circuit
return COMSIG_USB_CABLE_CONNECTED_TO_CIRCUIT