Files
Bubberstation/code/datums/wires/suit_storage_unit.dm
Jacquerel 14aef72a4a No roundstart playable MULEs / Trampling requires hacking (#76837)
## About The Pull Request

Prevailing feedback has been:
- The player base cannot be trusted to control MULEbots.
- It should be clearer what bots can and can't do.

The former is easy to fix.
The latter is sort of a matter for policy but I'm going to investigate
giving bots a rudimentary laws system. Plus that sounds much more
controversial than this so I am going to atomise this outside of that
PR.

MULEbots can still be set to allow sentience by cargo technicians, but
don't start that way.

ADDITIONALLY this PR just changes it so that MULEbots do not crush
people unless:
- They have been emagged.
- Their safety wire has been cut.
Either means works, so it's not too hard to access for nefarious
purposes, but hard to do to yourself.
Otherwise they just slow down for a few seconds instead.

Also fixed an unrelated name bug while I was there.

Closes #76926

## Why It's Good For The Game

Players would take them, not deliver any cargo, and repeatedly ask
people to lie down in front of them.
Plus Tram has 5 of the things which is frankly too many to be wandering
around the bar.

## Changelog

🆑
balance: You can't possess a MULE as soon as the round starts, someone
will have to give you permission.
balance: MULEbots no longer crush prone characters unless they have been
hacked (or emagged).
fix: Bots can put numbers in their names, what with being robots.
admin: Adds attack logging when certain wires are cut (for instance:
MULEbot safeties)
/🆑
2023-07-19 10:01:58 +02:00

48 lines
1.1 KiB
Plaintext

/datum/wires/suit_storage_unit
holder_type = /obj/machinery/suit_storage_unit
proper_name = "Suit Storage Unit"
/datum/wires/suit_storage_unit/New(atom/holder)
wires = list(
WIRE_HACK, WIRE_SAFETY,
WIRE_ZAP
)
add_duds(2)
..()
/datum/wires/suit_storage_unit/interactable(mob/user)
if(!..())
return FALSE
var/obj/machinery/suit_storage_unit/SSU = holder
if(SSU.panel_open)
return TRUE
/datum/wires/suit_storage_unit/get_status()
var/obj/machinery/suit_storage_unit/SSU = holder
var/list/status = list()
status += "The UV bulb is [SSU.uv_super ? "glowing" : "dim"]."
status += "The service light is [SSU.safeties ? "off" : "on"]."
return status
/datum/wires/suit_storage_unit/on_pulse(wire)
var/obj/machinery/suit_storage_unit/SSU = holder
switch(wire)
if(WIRE_HACK)
SSU.uv_super = !SSU.uv_super
if(WIRE_SAFETY)
SSU.safeties = !SSU.safeties
if(WIRE_ZAP)
if(usr)
SSU.shock(usr)
/datum/wires/suit_storage_unit/on_cut(wire, mend, source)
var/obj/machinery/suit_storage_unit/SSU = holder
switch(wire)
if(WIRE_HACK)
SSU.uv_super = !mend
if(WIRE_SAFETY)
SSU.safeties = mend
if(WIRE_ZAP)
if(usr)
SSU.shock(usr)