Files
Bubberstation/code/modules/events/electrical_storm.dm
SkyratBot 8add735177 [MIRROR] Return of the scrubber overflow event [MDB IGNORE] (#15998)
* Return of the scrubber overflow event (#68378)

About The Pull Request

Brings back the scrubber overflow event, previously removed in #53549
This version has nerfed numbers because foam changes made it stupidly powerful.

Also snake_cases some event variables.
Why It's Good For The Game

More dangerous but not station-damaging events. Bonus: janitor content.
Changelog

cl
add: Re-adds the scrubber overflow event as a random event
/cl

* Return of the scrubber overflow event

* update modular and fix missing non modular edit

* update stray meteor event

Co-authored-by: tattle <66640614+dragomagol@users.noreply.github.com>
Co-authored-by: Tom <8881105+tf-4@users.noreply.github.com>
2022-09-04 19:27:59 +01:00

35 lines
1017 B
Plaintext

/datum/round_event_control/electrical_storm
name = "Electrical Storm"
typepath = /datum/round_event/electrical_storm
earliest_start = 10 MINUTES
min_players = 5
weight = 20
category = EVENT_CATEGORY_ENGINEERING
description = "Destroys all lights in a large area."
/datum/round_event/electrical_storm
var/lightsoutAmount = 1
var/lightsoutRange = 25
announce_when = 1
/datum/round_event/electrical_storm/announce(fake)
priority_announce("An electrical storm has been detected in your area, please repair potential electronic overloads.", "Electrical Storm Alert", ANNOUNCER_ELECTRICALSTORM) //SKYRAT EDIT CHANGE
/datum/round_event/electrical_storm/start()
var/list/epicentreList = list()
for(var/i in 1 to lightsoutAmount)
var/turf/T = find_safe_turf()
if(istype(T))
epicentreList += T
if(!epicentreList.len)
return
for(var/centre in epicentreList)
for(var/a in GLOB.apcs_list)
var/obj/machinery/power/apc/A = a
if(get_dist(centre, A) <= lightsoutRange)
A.overload_lighting()