Merge pull request #38366 from AutomaticFrenzy/patch/fire-overlay

Replace area-wide fire overlay with reddening the lights
This commit is contained in:
oranges
2018-06-11 22:29:10 -05:00
committed by letterjay
parent ecd200a5bc
commit ffd705c8d7
4 changed files with 50 additions and 96 deletions
+13 -33
View File
@@ -23,9 +23,14 @@
idle_power_usage = 2
active_power_usage = 6
power_channel = ENVIRON
resistance_flags = FIRE_PROOF
light_power = 0
light_range = 7
light_color = "#ff3232"
var/detecting = 1
var/buildstage = 2 // 2 = complete, 1 = no wires, 0 = circuit gone
resistance_flags = FIRE_PROOF
var/last_alarm = 0
var/area/myarea = null
@@ -273,35 +278,10 @@
new /obj/item/stack/cable_coil(loc, 3)
qdel(src)
/*
* Party button
*/
/obj/machinery/firealarm/partyalarm
name = "\improper PARTY BUTTON"
desc = "Cuban Pete is in the house!"
/obj/machinery/firealarm/partyalarm/reset()
if (stat & (NOPOWER|BROKEN))
return
var/area/A = src.loc
A = A.loc
if (!( istype(A, /area) ))
return
A.partyreset()
/obj/machinery/firealarm/partyalarm/alarm()
if (stat & (NOPOWER|BROKEN))
return
var/area/A = src.loc
A = A.loc
if (!( istype(A, /area) ))
return
A.partyalert()
/obj/machinery/firealarm/partyalarm/ui_data(mob/user)
. = ..()
var/area/A = get_area(src)
.["alarm"] = A.party
/obj/machinery/firealarm/proc/update_fire_light(fire)
if(fire == !!light_power)
return // do nothing if we're already active
if(fire)
set_light(l_power = 0.8)
else
set_light(l_power = 0)