Skip to content

Commit

Permalink
[MIRROR] Fire Alarm Lights (Lit version) (Also lumin cleanup) [MDB IG…
Browse files Browse the repository at this point in the history
…NORE] (#1161)

* Fire Alarm Lights (Lit version) (Also lumin cleanup) (#80384)


---------

Co-authored-by: SkyratBot <[email protected]>
Co-authored-by: LemonInTheDark <[email protected]>
  • Loading branch information
3 people authored Dec 18, 2023
1 parent 14eb980 commit dc25592
Show file tree
Hide file tree
Showing 11 changed files with 12 additions and 32 deletions.
2 changes: 0 additions & 2 deletions code/game/machinery/doors/firedoor.dm
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@

COOLDOWN_DECLARE(activation_cooldown)

///Trick to get the glowing overlay visible from a distance
luminosity = 1
///X offset for the overlay lights, so that they line up with the thin border firelocks
var/light_xoffset = 0
///Y offset for the overlay lights, so that they line up with the thin border firelocks
Expand Down
6 changes: 2 additions & 4 deletions code/game/machinery/firealarm.dm
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@
light_range = 1.6
light_color = LIGHT_COLOR_ELECTRIC_CYAN

//Trick to get the glowing overlay visible from a distance
luminosity = 1
//We want to use area sensitivity, let us
always_area_sensitive = TRUE
///Buildstate for contruction steps
Expand Down Expand Up @@ -147,9 +145,9 @@
/obj/machinery/firealarm/update_appearance(updates)
. = ..()
if((my_area?.fire || LAZYLEN(my_area?.active_firelocks)) && !(obj_flags & EMAGGED) && !(machine_stat & (BROKEN|NOPOWER)))
set_light(l_power = 3)
set_light(l_range = 2.5, l_power = 1.5)
else
set_light(l_power = 1)
set_light(l_range = 1.6, l_power = 1)

/obj/machinery/firealarm/update_icon_state()
if(panel_open)
Expand Down
1 change: 0 additions & 1 deletion code/game/machinery/mining_weather_monitor.dm
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
desc = "A machine monitoring atmospheric data from mining environments. Provides warnings about incoming weather fronts."
icon = 'icons/obj/miningradio.dmi'
icon_state = "wallmount"
luminosity = 1
light_power = 1
light_range = 1.6

Expand Down
7 changes: 0 additions & 7 deletions code/game/machinery/recharger.dm
Original file line number Diff line number Diff line change
Expand Up @@ -197,13 +197,6 @@
if(batong.cell)
batong.cell.charge = 0

/obj/machinery/recharger/update_appearance(updates)
. = ..()
if((machine_stat & (NOPOWER|BROKEN)) || panel_open || !anchored)
luminosity = 0
return
luminosity = 1

/obj/machinery/recharger/update_overlays()
. = ..()
if(machine_stat & (NOPOWER|BROKEN) || !anchored)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ GLOBAL_LIST_EMPTY(heretic_sacrifice_landmarks)
nightshift_allowed = FALSE
bulb_colour = "#d6b6a6ff"
brightness = 3
fire_brightness = 2
fire_brightness = 3.5
bulb_power = 0.5

/obj/machinery/light/very_dim/directional/north
Expand Down
1 change: 0 additions & 1 deletion code/modules/mining/equipment/miningradio.dm
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
icon_state = "miningradio"
desc = "A weather radio designed for use in inhospitable environments. Gives audible warnings when storms approach. Has access to cargo channel."
freqlock = RADIO_FREQENCY_LOCKED
luminosity = 1
light_power = 1
light_range = 1.6

Expand Down
7 changes: 5 additions & 2 deletions code/modules/power/lighting/light.dm
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,9 @@
///The minimum value for the light's power in low power mode
var/bulb_low_power_pow_min = 0.5
///The Light range to use when working in fire alarm status
var/fire_brightness = 4
var/fire_brightness = 9
///The Light power to use when working in fire alarm status
var/fire_power = 0.5
///The Light colour to use when working in fire alarm status
var/fire_colour = COLOR_FIRE_LIGHT_RED

Expand Down Expand Up @@ -230,6 +232,7 @@
var/area/local_area = get_room_area()
if (local_area?.fire)
color_set = fire_colour
power_set = fire_power
brightness_set = fire_brightness
else if (nightshift_enabled)
brightness_set = nightshift_brightness
Expand Down Expand Up @@ -748,7 +751,7 @@
light_type = /obj/item/light/bulb
fitting = "bulb"
nightshift_brightness = 3
fire_brightness = 2
fire_brightness = 4.5

/obj/machinery/light/floor/get_light_offset()
return list(0, 0)
Expand Down
8 changes: 4 additions & 4 deletions code/modules/power/lighting/light_mapping_helpers.dm
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
/obj/machinery/light/red/dim
brightness = 4
bulb_power = 0.7
fire_brightness = 2
fire_brightness = 4.5

/obj/machinery/light/blacklight
bulb_colour = "#A700FF"
Expand All @@ -58,7 +58,7 @@
fitting = "bulb"
brightness = 4
nightshift_brightness = 4
fire_brightness = 3
fire_brightness = 4.5
bulb_colour = "#FFD6AA"
fire_colour = "#bd3f46"
desc = "A small lighting fixture."
Expand All @@ -85,13 +85,13 @@
/obj/machinery/light/small/red/dim
brightness = 2
bulb_power = 0.8
fire_brightness = 2
fire_brightness = 2.5

/obj/machinery/light/small/blacklight
bulb_colour = "#A700FF"
nightshift_allowed = FALSE
brightness = 4
fire_brightness = 3
fire_brightness = 4.5
fire_colour = "#d400ff"

// -------- Directional presets
Expand Down
7 changes: 0 additions & 7 deletions code/modules/recycling/disposal/bin.dm
Original file line number Diff line number Diff line change
Expand Up @@ -402,13 +402,6 @@
pressure_charging = TRUE
update_appearance()

/obj/machinery/disposal/bin/update_appearance(updates)
. = ..()
if((machine_stat & (BROKEN|NOPOWER)) || panel_open)
luminosity = 0
return
luminosity = 1

/obj/machinery/disposal/bin/update_overlays()
. = ..()
if(machine_stat & BROKEN)
Expand Down
1 change: 0 additions & 1 deletion code/modules/transport/elevator/elev_indicator.dm
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
light_range = 1
light_power = 1
light_color = COLOR_DISPLAY_BLUE
luminosity = 1

maptext_x = 18
maptext_y = 20
Expand Down
2 changes: 0 additions & 2 deletions code/modules/transport/tram/tram_signals.dm
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
// pointless if it only takes 2 seconds to cross but updates every 2 seconds
subsystem_type = /datum/controller/subsystem/processing/transport
light_color = LIGHT_COLOR_BABY_BLUE
luminosity = 1
/// green, amber, or red for tram, blue if it's emag, tram missing, etc.
var/signal_state = XING_STATE_MALF
/// the sensor we use
Expand Down Expand Up @@ -83,7 +82,6 @@
light_range = 1.5
light_power = 3
light_color = COLOR_VIBRANT_LIME
luminosity = 1
var/sign_dir = INBOUND

/obj/machinery/static_signal/northwest
Expand Down

0 comments on commit dc25592

Please sign in to comment.