mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-01-02 05:22:40 +00:00
Updates gridcheck behavior
- Gridcheck random event is updated. Core behavior remains the same, but mechanism it uses to achieve power outage is changed. - Both SMESs and APCs have new variable which is set by gridcheck. This variable decrements by 1 every tick, and until it is back to zero the APC/SMES won't work. - SMESs are disabled for 60-120 seconds (random for each SMES). APCs for 120-240 seconds. - Both SMESs and APCs show error UI with timer counting down until the device restarts (begins working again). - Both SMEss and APCs may be manually restarted, on per-device basis, by clicking restart button in the UI. This is useful if you urgently need one or two devices back online, for example, medical treatment facilities, etc. This immediately skips the X second timer and restores the device to working state, while keeping the original intention of this event - allowing antagonists to use lack of power to enter areas they don't normally have access to.
This commit is contained in:
@@ -1,15 +1,8 @@
|
||||
/datum/event/grid_check //NOTE: Times are measured in master controller ticks!
|
||||
announceWhen = 5
|
||||
|
||||
/datum/event/grid_check/setup()
|
||||
endWhen = rand(30,120)
|
||||
|
||||
/datum/event/grid_check/start()
|
||||
power_failure(0)
|
||||
|
||||
/datum/event/grid_check/announce()
|
||||
if (prob(30))
|
||||
command_announcement.Announce("Abnormal activity detected in [station_name()]'s powernet. As a precautionary measure, the station's power will be shut off for an indeterminate duration.", "Automated Grid Check", new_sound = 'sound/AI/poweroff.ogg')
|
||||
|
||||
/datum/event/grid_check/end()
|
||||
power_restore()
|
||||
command_announcement.Announce("Abnormal activity detected in [station_name()]'s powernet. As a precautionary measure, the station's power will be shut off for an indeterminate duration.", "Automated Grid Check", new_sound = 'sound/AI/poweroff.ogg')
|
||||
Reference in New Issue
Block a user