From 4f53ec2660041b6c525d711aa66b8faa0ec6469b Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Mon, 12 Feb 2024 23:25:22 +0100 Subject: [PATCH] [MIRROR] Fixes complex lights not handling moving well, renames lighting defines (#26484) * Fixes complex lights not handling moving well, renames lighting defines (#81423) ## About The Pull Request [Fixes static lights not moving](https://github.com/tgstation/tgstation/commit/ffef43c05a55dae414ef94558ecf9b9df709ded7) Worked fine when the owner moved, but if the owner was inside something else, it would try and trigger an update on the PARENT's lights, which are obviously not us. [Renames MOVABLE_LIGHT and STATIC_LIGHT to better describe what they do](https://github.com/tgstation/tgstation/commit/de73a63bd4d97783c69c95370726d1c253ffb8fe) People keep trying to change the lighting system of lamps and it makes me mad. I choose OVERLAY_LIGHT and COMPLEX_LIGHT here, I couldn't figure out a better name for turf matrix lighting. Suggestions welcome ## Why It's Good For The Game Closes #80005 Hopefully improves understanding of lighting at a glance ## Changelog :cl: fix: Fixes fancy lights not updating their source location when picked up and moved /:cl: * Oh well --------- Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com> Co-authored-by: Useroth <37159550+Useroth@users.noreply.github.com> --- code/__DEFINES/lighting.dm | 10 ++++---- code/_onclick/hud/rendering/render_plate.dm | 2 +- code/datums/components/overlay_lighting.dm | 4 ++-- code/datums/elements/light_eaten.dm | 4 ++-- code/game/atom/_atom.dm | 2 +- code/game/atom/atom_vv.dm | 14 +++++------ .../game/atom/atoms_initializing_EXPENSIVE.dm | 2 +- code/game/atoms_movable.dm | 6 ++--- .../effects/effect_system/effects_sparks.dm | 2 +- code/game/objects/effects/lighting.dm | 2 +- code/game/objects/effects/portals.dm | 2 +- code/game/objects/items/cigs_lighters.dm | 2 +- code/game/objects/items/devices/flashlight.dm | 22 ++++++++--------- code/game/objects/items/dualsaber.dm | 2 +- code/game/objects/items/flamethrower.dm | 2 +- code/game/objects/items/melee/energy.dm | 2 +- .../stacks/golem_food/golem_status_effects.dm | 2 +- code/game/objects/items/tools/weldingtool.dm | 2 +- .../antagonists/heretic/items/keyring.dm | 2 +- code/modules/assembly/flash.dm | 2 +- .../atmospherics/environmental/LINDA_fire.dm | 2 +- code/modules/clothing/head/cakehat.dm | 2 +- code/modules/clothing/head/hardhat.dm | 2 +- code/modules/clothing/shoes/kindlekicks.dm | 2 +- code/modules/clothing/spacesuits/plasmamen.dm | 2 +- code/modules/hydroponics/grown/ambrosia.dm | 2 +- code/modules/hydroponics/plant_genes.dm | 2 +- code/modules/lighting/lighting_atom.dm | 2 +- code/modules/lighting/lighting_source.dm | 24 +++++++++++-------- .../mining/boulder_processing/refinery.dm | 2 +- .../mining/equipment/kinetic_crusher.dm | 2 +- code/modules/mining/lavaland/tendril_loot.dm | 2 +- code/modules/mob/dead/observer/observer.dm | 2 +- code/modules/mob/living/basic/bots/_bots.dm | 2 +- .../mob/living/basic/guardian/guardian.dm | 2 +- .../mob/living/basic/minebots/minebot.dm | 2 +- .../mob/living/basic/space_fauna/ghost.dm | 2 +- .../mob/living/silicon/robot/robot_defines.dm | 2 +- .../mob/living/simple_animal/bot/bot.dm | 2 +- .../mob/living/simple_animal/bot/vibebot.dm | 2 +- .../hostile/megafauna/colossus.dm | 2 +- code/modules/mod/mod_construction.dm | 2 +- code/modules/mod/mod_core.dm | 2 +- code/modules/mod/modules/modules_general.dm | 2 +- code/modules/mod/modules/modules_supply.dm | 4 ++-- .../computers/item/computer.dm | 2 +- code/modules/pai/pai.dm | 2 +- code/modules/paperwork/pen.dm | 2 +- code/modules/photography/camera/camera.dm | 2 +- code/modules/projectiles/projectile/beams.dm | 2 +- .../research/ordnance/doppler_array.dm | 2 +- code/modules/surgery/tools.dm | 4 ++-- code/modules/vehicles/cars/clowncar.dm | 2 +- code/modules/vehicles/cars/vim.dm | 2 +- code/modules/vehicles/mecha/_mecha.dm | 2 +- code/modules/vehicles/mecha/combat/durand.dm | 2 +- code/modules/wiremod/shell/bot.dm | 2 +- code/modules/wiremod/shell/compact_remote.dm | 2 +- code/modules/wiremod/shell/controller.dm | 2 +- code/modules/wiremod/shell/dispenser.dm | 2 +- code/modules/wiremod/shell/drone.dm | 2 +- code/modules/wiremod/shell/gun.dm | 2 +- code/modules/wiremod/shell/keyboard.dm | 2 +- code/modules/wiremod/shell/moneybot.dm | 2 +- code/modules/wiremod/shell/scanner.dm | 2 +- code/modules/wiremod/shell/server.dm | 2 +- .../mob/living/simple_animal/friendly/dogs.dm | 2 +- .../living/simple_animal/friendly/poppy.dm | 2 +- .../modules/energy_axe/code/energy_fireaxe.dm | 2 +- .../lewd_items/code/lewd_items/shibari.dm | 2 +- .../code/lewd_structures/dancing_pole.dm | 2 +- .../modular_weapons/code/ballistic_master.dm | 2 +- modular_skyrat/modules/mold/code/mold_mobs.dm | 4 ++-- 73 files changed, 113 insertions(+), 109 deletions(-) diff --git a/code/__DEFINES/lighting.dm b/code/__DEFINES/lighting.dm index dba718901fb..48a27ea88a4 100644 --- a/code/__DEFINES/lighting.dm +++ b/code/__DEFINES/lighting.dm @@ -1,17 +1,17 @@ /// Object doesn't use any of the light systems. Should be changed to add a light source to the object. #define NO_LIGHT_SUPPORT 0 /// Light made with the lighting datums, applying a matrix. -#define STATIC_LIGHT 1 +#define COMPLEX_LIGHT 1 /// Light made by masking the lighting darkness plane. -#define MOVABLE_LIGHT 2 +#define OVERLAY_LIGHT 2 /// Light made by masking the lighting darkness plane, and is directional. -#define MOVABLE_LIGHT_DIRECTIONAL 3 +#define OVERLAY_LIGHT_DIRECTIONAL 3 ///Light made by masking the lighting darkness plane, and is a directionally focused beam. -#define MOVABLE_LIGHT_BEAM 4 +#define OVERLAY_LIGHT_BEAM 4 /// Nonesensical value for light color, used for null checks. #define NONSENSICAL_VALUE -99999 -/// Is a movable light source attached to another movable (its loc), meaning that the lighting component should go one level deeper. +/// Is our overlay light source attached to another movable (its loc), meaning that the lighting component should go one level deeper. #define LIGHT_ATTACHED (1<<0) /// Freezes a light in its current state, blocking any attempts at modification #define LIGHT_FROZEN (1<<1) diff --git a/code/_onclick/hud/rendering/render_plate.dm b/code/_onclick/hud/rendering/render_plate.dm index e42c1f94f68..d33162a5b5f 100644 --- a/code/_onclick/hud/rendering/render_plate.dm +++ b/code/_onclick/hud/rendering/render_plate.dm @@ -212,7 +212,7 @@
That's how lighting functions at base. Because it uses BLEND_MULTIPLY and occasionally color matrixes, it needs a backdrop of blackness.\
See This byond post\
Lemme see uh, we're masked by the emissive plane so it can actually function (IE: make things glow in the dark).\ -
We're also masked by the overlay lighting plane, which contains all the movable lights in the game. It draws to us and also the game plane.\ +
We're also masked by the overlay lighting plane, which contains all the well overlay lights in the game. It draws to us and also the game plane.\
Masks us out so it has the breathing room to apply its effect.\
Oh and we quite often have our alpha changed to achive night vision effects, or things of that sort." plane = RENDER_PLANE_LIGHTING diff --git a/code/datums/components/overlay_lighting.dm b/code/datums/components/overlay_lighting.dm index 180c65b2239..efff82b703a 100644 --- a/code/datums/components/overlay_lighting.dm +++ b/code/datums/components/overlay_lighting.dm @@ -78,8 +78,8 @@ return COMPONENT_INCOMPATIBLE var/atom/movable/movable_parent = parent - if(movable_parent.light_system != MOVABLE_LIGHT && movable_parent.light_system != MOVABLE_LIGHT_DIRECTIONAL && movable_parent.light_system != MOVABLE_LIGHT_BEAM) - stack_trace("[type] added to [parent], with [movable_parent.light_system] value for the light_system var. Use [MOVABLE_LIGHT], [MOVABLE_LIGHT_DIRECTIONAL] or [MOVABLE_LIGHT_BEAM] instead.") + if(movable_parent.light_system != OVERLAY_LIGHT && movable_parent.light_system != OVERLAY_LIGHT_DIRECTIONAL && movable_parent.light_system != OVERLAY_LIGHT_BEAM) + stack_trace("[type] added to [parent], with [movable_parent.light_system] value for the light_system var. Use [OVERLAY_LIGHT], [OVERLAY_LIGHT_DIRECTIONAL] or [OVERLAY_LIGHT_BEAM] instead.") return COMPONENT_INCOMPATIBLE . = ..() diff --git a/code/datums/elements/light_eaten.dm b/code/datums/elements/light_eaten.dm index 39550a99124..e3bcc079318 100644 --- a/code/datums/elements/light_eaten.dm +++ b/code/datums/elements/light_eaten.dm @@ -15,9 +15,9 @@ RegisterSignal(atom_target, COMSIG_ATOM_SET_LIGHT_ON, PROC_REF(block_light_on)) RegisterSignal(atom_target, COMSIG_ATOM_EXAMINE, PROC_REF(on_examine)) - /// Because the lighting system does not like movable lights getting set_light() called. + /// Because the lighting system does not like overlay lights getting set_light() called. switch(atom_target.light_system) - if(STATIC_LIGHT) + if(COMPLEX_LIGHT) target.set_light(0, 0, null, l_on = FALSE) else target.set_light_power(0) diff --git a/code/game/atom/_atom.dm b/code/game/atom/_atom.dm index 96c0846578f..71b86bafe72 100644 --- a/code/game/atom/_atom.dm +++ b/code/game/atom/_atom.dm @@ -65,7 +65,7 @@ var/datum/wires/wires = null ///Light systems, both shouldn't be active at the same time. - var/light_system = STATIC_LIGHT + var/light_system = COMPLEX_LIGHT ///Range of the light in tiles. Zero means no light. var/light_range = 0 ///Intensity of the light. The stronger, the less shadows you will see on the lit area. diff --git a/code/game/atom/atom_vv.dm b/code/game/atom/atom_vv.dm index b5a572749a6..8830a4af2f4 100644 --- a/code/game/atom/atom_vv.dm +++ b/code/game/atom/atom_vv.dm @@ -222,37 +222,37 @@ light_flags &= ~LIGHT_FROZEN switch(var_name) if(NAMEOF(src, light_range)) - if(light_system == STATIC_LIGHT) + if(light_system == COMPLEX_LIGHT) set_light(l_range = var_value) else set_light_range(var_value) . = TRUE if(NAMEOF(src, light_power)) - if(light_system == STATIC_LIGHT) + if(light_system == COMPLEX_LIGHT) set_light(l_power = var_value) else set_light_power(var_value) . = TRUE if(NAMEOF(src, light_color)) - if(light_system == STATIC_LIGHT) + if(light_system == COMPLEX_LIGHT) set_light(l_color = var_value) else set_light_color(var_value) . = TRUE if(NAMEOF(src, light_angle)) - if(light_system == STATIC_LIGHT) + if(light_system == COMPLEX_LIGHT) set_light(l_angle = var_value) . = TRUE if(NAMEOF(src, light_dir)) - if(light_system == STATIC_LIGHT) + if(light_system == COMPLEX_LIGHT) set_light(l_dir = var_value) . = TRUE if(NAMEOF(src, light_height)) - if(light_system == STATIC_LIGHT) + if(light_system == COMPLEX_LIGHT) set_light(l_height = var_value) . = TRUE if(NAMEOF(src, light_on)) - if(light_system == STATIC_LIGHT) + if(light_system == COMPLEX_LIGHT) set_light(l_on = var_value) else set_light_on(var_value) diff --git a/code/game/atom/atoms_initializing_EXPENSIVE.dm b/code/game/atom/atoms_initializing_EXPENSIVE.dm index 2a3a442e04d..ea8bf9b125d 100644 --- a/code/game/atom/atoms_initializing_EXPENSIVE.dm +++ b/code/game/atom/atoms_initializing_EXPENSIVE.dm @@ -128,7 +128,7 @@ if(color) add_atom_colour(color, FIXED_COLOUR_PRIORITY) - if (light_system == STATIC_LIGHT && light_power && light_range) + if (light_system == COMPLEX_LIGHT && light_power && light_range) update_light() SETUP_SMOOTHING() diff --git a/code/game/atoms_movable.dm b/code/game/atoms_movable.dm index f70a9f6669b..9603e87067d 100644 --- a/code/game/atoms_movable.dm +++ b/code/game/atoms_movable.dm @@ -181,11 +181,11 @@ if(opacity) AddElement(/datum/element/light_blocking) switch(light_system) - if(MOVABLE_LIGHT) + if(OVERLAY_LIGHT) AddComponent(/datum/component/overlay_lighting) - if(MOVABLE_LIGHT_DIRECTIONAL) + if(OVERLAY_LIGHT_DIRECTIONAL) AddComponent(/datum/component/overlay_lighting, is_directional = TRUE) - if(MOVABLE_LIGHT_BEAM) + if(OVERLAY_LIGHT_BEAM) AddComponent(/datum/component/overlay_lighting, is_directional = TRUE, is_beam = TRUE) /atom/movable/Destroy(force) diff --git a/code/game/objects/effects/effect_system/effects_sparks.dm b/code/game/objects/effects/effect_system/effects_sparks.dm index 86800d0522c..c3fad6d26b6 100644 --- a/code/game/objects/effects/effect_system/effects_sparks.dm +++ b/code/game/objects/effects/effect_system/effects_sparks.dm @@ -16,7 +16,7 @@ name = "sparks" icon_state = "sparks" anchored = TRUE - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 2 light_power = 0.5 light_color = LIGHT_COLOR_FIRE diff --git a/code/game/objects/effects/lighting.dm b/code/game/objects/effects/lighting.dm index 4e95e72f429..1de9fad39ee 100644 --- a/code/game/objects/effects/lighting.dm +++ b/code/game/objects/effects/lighting.dm @@ -8,7 +8,7 @@ name = "lighting" desc = "Tell a coder if you're seeing this." icon_state = "nothing" - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = MINIMUM_USEFUL_LIGHT_RANGE light_color = COLOR_WHITE blocks_emissive = EMISSIVE_BLOCK_NONE diff --git a/code/game/objects/effects/portals.dm b/code/game/objects/effects/portals.dm index 091b4700673..8c52a76dbc0 100644 --- a/code/game/objects/effects/portals.dm +++ b/code/game/objects/effects/portals.dm @@ -18,7 +18,7 @@ anchored = TRUE density = TRUE // dense for receiving bumbs layer = HIGH_OBJ_LAYER - light_system = STATIC_LIGHT + light_system = COMPLEX_LIGHT light_range = 3 light_power = 1 light_on = TRUE diff --git a/code/game/objects/items/cigs_lighters.dm b/code/game/objects/items/cigs_lighters.dm index e9378d505f3..a46732f171a 100644 --- a/code/game/objects/items/cigs_lighters.dm +++ b/code/game/objects/items/cigs_lighters.dm @@ -742,7 +742,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM resistance_flags = FIRE_PROOF grind_results = list(/datum/reagent/iron = 1, /datum/reagent/fuel = 5, /datum/reagent/fuel/oil = 5) custom_price = PAYCHECK_CREW * 1.1 - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 2 light_power = 0.6 light_color = LIGHT_COLOR_FIRE diff --git a/code/game/objects/items/devices/flashlight.dm b/code/game/objects/items/devices/flashlight.dm index 564e1423961..6ea3b516069 100644 --- a/code/game/objects/items/devices/flashlight.dm +++ b/code/game/objects/items/devices/flashlight.dm @@ -19,7 +19,7 @@ slot_flags = ITEM_SLOT_BELT custom_materials = list(/datum/material/iron= SMALL_MATERIAL_AMOUNT * 0.5, /datum/material/glass= SMALL_MATERIAL_AMOUNT * 0.2) actions_types = list(/datum/action/item_action/toggle_light) - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_range = 4 light_power = 1 light_on = FALSE @@ -76,7 +76,7 @@ /obj/item/flashlight/proc/update_brightness() update_appearance(UPDATE_ICON) - if(light_system == STATIC_LIGHT) + if(light_system == COMPLEX_LIGHT) update_light() /obj/item/flashlight/proc/toggle_light(mob/user) @@ -364,7 +364,7 @@ righthand_file = 'icons/mob/inhands/items_righthand.dmi' force = 10 light_range = 3.5 - light_system = STATIC_LIGHT + light_system = COMPLEX_LIGHT light_color = LIGHT_COLOR_FAINT_BLUE w_class = WEIGHT_CLASS_BULKY obj_flags = CONDUCTS_ELECTRICITY @@ -397,7 +397,7 @@ actions_types = list() heat = 1000 light_color = LIGHT_COLOR_FLARE - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT grind_results = list(/datum/reagent/sulfur = 15) sound_on = 'sound/items/match_strike.ogg' toggle_context = FALSE @@ -656,7 +656,7 @@ righthand_file = 'icons/mob/inhands/equipment/mining_righthand.dmi' desc = "A mining lantern." light_range = 6 // luminosity when on - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT /obj/item/flashlight/lantern/heirloom_moth name = "old lantern" @@ -687,7 +687,7 @@ slot_flags = ITEM_SLOT_BELT custom_materials = null light_range = 7 //luminosity when on - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT /obj/item/flashlight/emp special_desc_requirement = EXAMINE_CHECK_SYNDICATE // SKYRAT EDIT @@ -753,7 +753,7 @@ custom_price = PAYCHECK_LOWER w_class = WEIGHT_CLASS_SMALL light_range = 4 - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT color = LIGHT_COLOR_GREEN icon_state = "glowstick" base_icon_state = "glowstick" @@ -860,7 +860,7 @@ name = "disco light" desc = "Groovy..." icon_state = null - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 4 light_power = 10 alpha = 0 @@ -888,7 +888,7 @@ desc = "A strange device manufactured with mysterious elements that somehow emits darkness. Or maybe it just sucks in light? Nobody knows for sure." icon_state = "flashdark" inhand_icon_state = "flashdark" - light_system = STATIC_LIGHT //The overlay light component is not yet ready to produce darkness. + light_system = COMPLEX_LIGHT //The overlay light component is not yet ready to produce darkness. light_range = 0 ///Variable to preserve old lighting behavior in flashlights, to handle darkness. var/dark_light_range = 2.5 @@ -907,7 +907,7 @@ /obj/item/flashlight/eyelight name = "eyelight" desc = "This shouldn't exist outside of someone's head, how are you seeing this?" - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 15 light_power = 1 obj_flags = CONDUCTS_ELECTRICITY @@ -915,7 +915,7 @@ actions_types = list() /obj/item/flashlight/eyelight/glow - light_system = MOVABLE_LIGHT_BEAM + light_system = OVERLAY_LIGHT_BEAM light_range = 4 light_power = 2 diff --git a/code/game/objects/items/dualsaber.dm b/code/game/objects/items/dualsaber.dm index 78f845b37b7..f52d9bc527e 100644 --- a/code/game/objects/items/dualsaber.dm +++ b/code/game/objects/items/dualsaber.dm @@ -17,7 +17,7 @@ w_class = WEIGHT_CLASS_SMALL hitsound = SFX_SWING_HIT armour_penetration = 35 - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 6 //TWICE AS BRIGHT AS A REGULAR ESWORD light_color = LIGHT_COLOR_ELECTRIC_GREEN light_on = FALSE diff --git a/code/game/objects/items/flamethrower.dm b/code/game/objects/items/flamethrower.dm index b7896c64381..1a31c5d58a2 100644 --- a/code/game/objects/items/flamethrower.dm +++ b/code/game/objects/items/flamethrower.dm @@ -15,7 +15,7 @@ custom_materials = list(/datum/material/iron= HALF_SHEET_MATERIAL_AMOUNT * 0.5) resistance_flags = FIRE_PROOF trigger_guard = TRIGGER_GUARD_NORMAL - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_on = FALSE var/status = FALSE var/lit = FALSE //on or off diff --git a/code/game/objects/items/melee/energy.dm b/code/game/objects/items/melee/energy.dm index d07f05169e8..9c6da93717a 100644 --- a/code/game/objects/items/melee/energy.dm +++ b/code/game/objects/items/melee/energy.dm @@ -5,7 +5,7 @@ attack_verb_continuous = list("hits", "taps", "pokes") attack_verb_simple = list("hit", "tap", "poke") resistance_flags = FIRE_PROOF - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 3 light_power = 1 light_on = FALSE diff --git a/code/game/objects/items/stacks/golem_food/golem_status_effects.dm b/code/game/objects/items/stacks/golem_food/golem_status_effects.dm index c89fae800b9..31600b03354 100644 --- a/code/game/objects/items/stacks/golem_food/golem_status_effects.dm +++ b/code/game/objects/items/stacks/golem_food/golem_status_effects.dm @@ -441,7 +441,7 @@ if (!.) return to_chat(owner, span_notice("You start to emit a healthy glow.")) - owner.light_system = MOVABLE_LIGHT + owner.light_system = OVERLAY_LIGHT lightbulb = owner.AddComponent(/datum/component/overlay_lighting, _range = glow_range, _power = glow_power, _color = glow_color) owner.add_filter(LIGHTBULB_FILTER, 2, list("type" = "outline", "color" = glow_color, "alpha" = 60, "size" = 1)) diff --git a/code/game/objects/items/tools/weldingtool.dm b/code/game/objects/items/tools/weldingtool.dm index b7bb18e5981..a2e33171b0b 100644 --- a/code/game/objects/items/tools/weldingtool.dm +++ b/code/game/objects/items/tools/weldingtool.dm @@ -17,7 +17,7 @@ usesound = list('sound/items/welder.ogg', 'sound/items/welder2.ogg') drop_sound = 'sound/items/handling/weldingtool_drop.ogg' pickup_sound = 'sound/items/handling/weldingtool_pickup.ogg' - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 2 light_power = 0.75 light_color = LIGHT_COLOR_FIRE diff --git a/code/modules/antagonists/heretic/items/keyring.dm b/code/modules/antagonists/heretic/items/keyring.dm index a6a53bc3cee..b71015dbfe1 100644 --- a/code/modules/antagonists/heretic/items/keyring.dm +++ b/code/modules/antagonists/heretic/items/keyring.dm @@ -3,7 +3,7 @@ desc = "A crack in space, impossibly deep and painful to the eyes. Definitely not safe." icon = 'icons/effects/eldritch.dmi' icon_state = "realitycrack" - light_system = STATIC_LIGHT + light_system = COMPLEX_LIGHT light_power = 1 light_on = TRUE light_color = COLOR_GREEN diff --git a/code/modules/assembly/flash.dm b/code/modules/assembly/flash.dm index a09185df3b5..5319d4465e2 100644 --- a/code/modules/assembly/flash.dm +++ b/code/modules/assembly/flash.dm @@ -11,7 +11,7 @@ throwforce = 0 w_class = WEIGHT_CLASS_TINY custom_materials = list(/datum/material/iron = SMALL_MATERIAL_AMOUNT*3, /datum/material/glass = SMALL_MATERIAL_AMOUNT*3) - light_system = MOVABLE_LIGHT //Used as a flash here. + light_system = OVERLAY_LIGHT //Used as a flash here. light_range = FLASH_LIGHT_RANGE light_color = COLOR_WHITE light_power = FLASH_LIGHT_POWER diff --git a/code/modules/atmospherics/environmental/LINDA_fire.dm b/code/modules/atmospherics/environmental/LINDA_fire.dm index 4145ae7fa76..fc4fc96ee71 100644 --- a/code/modules/atmospherics/environmental/LINDA_fire.dm +++ b/code/modules/atmospherics/environmental/LINDA_fire.dm @@ -78,7 +78,7 @@ layer = GASFIRE_LAYER plane = ABOVE_GAME_PLANE blend_mode = BLEND_ADD - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = LIGHT_RANGE_FIRE light_power = 1 light_color = LIGHT_COLOR_FIRE diff --git a/code/modules/clothing/head/cakehat.dm b/code/modules/clothing/head/cakehat.dm index 4a05ff7116f..57369ac24f8 100644 --- a/code/modules/clothing/head/cakehat.dm +++ b/code/modules/clothing/head/cakehat.dm @@ -10,7 +10,7 @@ righthand_file = 'icons/mob/inhands/clothing/hats_righthand.dmi' armor_type = /datum/armor/none light_range = 2 //luminosity when on - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT flags_cover = HEADCOVERSEYES heat = 999 wound_bonus = 10 diff --git a/code/modules/clothing/head/hardhat.dm b/code/modules/clothing/head/hardhat.dm index 09c67e7534a..ce6becd524e 100644 --- a/code/modules/clothing/head/hardhat.dm +++ b/code/modules/clothing/head/hardhat.dm @@ -13,7 +13,7 @@ clothing_flags = SNUG_FIT | STACKABLE_HELMET_EXEMPT resistance_flags = FIRE_PROOF - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_range = 4 light_power = 0.8 light_on = FALSE diff --git a/code/modules/clothing/shoes/kindlekicks.dm b/code/modules/clothing/shoes/kindlekicks.dm index 82bcb806515..339ec9669af 100644 --- a/code/modules/clothing/shoes/kindlekicks.dm +++ b/code/modules/clothing/shoes/kindlekicks.dm @@ -4,7 +4,7 @@ icon_state = "kindleKicks" inhand_icon_state = null actions_types = list(/datum/action/item_action/kindle_kicks) - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 2 light_power = 3 light_on = FALSE diff --git a/code/modules/clothing/spacesuits/plasmamen.dm b/code/modules/clothing/spacesuits/plasmamen.dm index 30e43c793aa..90141d281dd 100644 --- a/code/modules/clothing/spacesuits/plasmamen.dm +++ b/code/modules/clothing/spacesuits/plasmamen.dm @@ -52,7 +52,7 @@ tint = 2 armor_type = /datum/armor/space_plasmaman resistance_flags = FIRE_PROOF - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_range = 4 light_on = FALSE var/helmet_on = FALSE diff --git a/code/modules/hydroponics/grown/ambrosia.dm b/code/modules/hydroponics/grown/ambrosia.dm index a2afcdc729f..aa02ba7efa1 100644 --- a/code/modules/hydroponics/grown/ambrosia.dm +++ b/code/modules/hydroponics/grown/ambrosia.dm @@ -72,7 +72,7 @@ name = "ambrosia gaia branch" desc = "Eating this makes you immortal." icon_state = "ambrosia_gaia" - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 3 seed = /obj/item/seeds/ambrosia/gaia wine_power = 70 diff --git a/code/modules/hydroponics/plant_genes.dm b/code/modules/hydroponics/plant_genes.dm index 98eef6b816e..2ce685d0b7c 100644 --- a/code/modules/hydroponics/plant_genes.dm +++ b/code/modules/hydroponics/plant_genes.dm @@ -368,7 +368,7 @@ return var/obj/item/seeds/our_seed = our_plant.get_plant_seed() - our_plant.light_system = MOVABLE_LIGHT + our_plant.light_system = OVERLAY_LIGHT our_plant.AddComponent(/datum/component/overlay_lighting, glow_range(our_seed), glow_power(our_seed), glow_color) /* diff --git a/code/modules/lighting/lighting_atom.dm b/code/modules/lighting/lighting_atom.dm index 5d82c33e23f..e3f72da5bbf 100644 --- a/code/modules/lighting/lighting_atom.dm +++ b/code/modules/lighting/lighting_atom.dm @@ -44,7 +44,7 @@ /atom/proc/update_light() SHOULD_NOT_SLEEP(TRUE) - if(light_system != STATIC_LIGHT) + if(light_system != COMPLEX_LIGHT) CRASH("update_light() for [src] with following light_system value: [light_system]") if (!light_power || !light_range || !light_on) // We won't emit light anyways, destroy the light source. diff --git a/code/modules/lighting/lighting_source.dm b/code/modules/lighting/lighting_source.dm index 90af6a855ce..1a32686aa19 100644 --- a/code/modules/lighting/lighting_source.dm +++ b/code/modules/lighting/lighting_source.dm @@ -80,7 +80,7 @@ if (needs_update) SSlighting.sources_queue -= src SSlighting.current_sources -= src - + top_atom = null source_atom = null source_turf = null @@ -107,15 +107,6 @@ UnregisterSignal(old_atom_host, COMSIG_MOVABLE_MOVED) return TRUE -///signal handler for when our host atom moves and we need to update our effects -/datum/light_source/proc/update_host_lights(atom/movable/host) - SIGNAL_HANDLER - - if(QDELETED(host)) - return - - host.update_light() - // Yes this doesn't align correctly on anything other than 4 width tabs. // If you want it to go switch everybody to elastic tab stops. // Actually that'd be great if you could! @@ -127,6 +118,19 @@ needs_update = level; \ } +///signal handler for when our host atom moves and we need to update our effects +/datum/light_source/proc/update_host_lights(atom/movable/host) + SIGNAL_HANDLER + if(QDELETED(host)) + return + + // If the host is our owner, we want to call their update so they can decide who the top atom should be + if(host == source_atom) + host.update_light() + return + + // Otherwise, our top atom just moved, so we trigger a normal rebuild + EFFECT_UPDATE(LIGHTING_CHECK_UPDATE) /// This proc will cause the light source to update the top atom, and add itself to the update queue. /datum/light_source/proc/update(atom/new_top_atom) diff --git a/code/modules/mining/boulder_processing/refinery.dm b/code/modules/mining/boulder_processing/refinery.dm index a6c6c2e7dfc..764816ec6d3 100644 --- a/code/modules/mining/boulder_processing/refinery.dm +++ b/code/modules/mining/boulder_processing/refinery.dm @@ -65,7 +65,7 @@ /datum/material/adamantine, /datum/material/runite, ) - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 1 light_power = 2 light_color = "#ffaf55" diff --git a/code/modules/mining/equipment/kinetic_crusher.dm b/code/modules/mining/equipment/kinetic_crusher.dm index add06da08a6..e1df98239e2 100644 --- a/code/modules/mining/equipment/kinetic_crusher.dm +++ b/code/modules/mining/equipment/kinetic_crusher.dm @@ -21,7 +21,7 @@ sharpness = SHARP_EDGED actions_types = list(/datum/action/item_action/toggle_light) obj_flags = UNIQUE_RENAME - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 5 light_on = FALSE var/list/trophies = list() diff --git a/code/modules/mining/lavaland/tendril_loot.dm b/code/modules/mining/lavaland/tendril_loot.dm index 5ccfaa92874..310c12940a7 100644 --- a/code/modules/mining/lavaland/tendril_loot.dm +++ b/code/modules/mining/lavaland/tendril_loot.dm @@ -271,7 +271,7 @@ desc = "Happy to light your way." icon = 'icons/obj/lighting.dmi' icon_state = "orb" - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 7 light_flags = LIGHT_ATTACHED layer = ABOVE_ALL_MOB_LAYER diff --git a/code/modules/mob/dead/observer/observer.dm b/code/modules/mob/dead/observer/observer.dm index 25e02ff687e..26250d0d7a7 100644 --- a/code/modules/mob/dead/observer/observer.dm +++ b/code/modules/mob/dead/observer/observer.dm @@ -16,7 +16,7 @@ GLOBAL_VAR_INIT(observer_default_invisibility, INVISIBILITY_OBSERVER) invisibility = INVISIBILITY_OBSERVER hud_type = /datum/hud/ghost movement_type = GROUND | FLYING - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 1 light_power = 2 light_on = FALSE diff --git a/code/modules/mob/living/basic/bots/_bots.dm b/code/modules/mob/living/basic/bots/_bots.dm index 8462f4afc35..56fdc4fc938 100644 --- a/code/modules/mob/living/basic/bots/_bots.dm +++ b/code/modules/mob/living/basic/bots/_bots.dm @@ -35,7 +35,7 @@ GLOBAL_LIST_INIT(command_strings, list( bubble_icon = "machine" speech_span = SPAN_ROBOT faction = list(FACTION_NEUTRAL, FACTION_SILICON, FACTION_TURRET) - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 3 light_power = 0.9 speed = 3 diff --git a/code/modules/mob/living/basic/guardian/guardian.dm b/code/modules/mob/living/basic/guardian/guardian.dm index 9d79373ccd4..b338a5a4435 100644 --- a/code/modules/mob/living/basic/guardian/guardian.dm +++ b/code/modules/mob/living/basic/guardian/guardian.dm @@ -39,7 +39,7 @@ melee_damage_lower = 15 melee_damage_upper = 15 melee_attack_cooldown = CLICK_CD_MELEE - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 3 light_on = FALSE diff --git a/code/modules/mob/living/basic/minebots/minebot.dm b/code/modules/mob/living/basic/minebots/minebot.dm index f9a22f955f1..5422ab4ee2e 100644 --- a/code/modules/mob/living/basic/minebots/minebot.dm +++ b/code/modules/mob/living/basic/minebots/minebot.dm @@ -23,7 +23,7 @@ speak_emote = list("states") mob_biotypes = MOB_ROBOTIC death_message = "blows apart!" - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 6 light_on = FALSE combat_mode = FALSE diff --git a/code/modules/mob/living/basic/space_fauna/ghost.dm b/code/modules/mob/living/basic/space_fauna/ghost.dm index 981357d1a13..406d2ecefdd 100644 --- a/code/modules/mob/living/basic/space_fauna/ghost.dm +++ b/code/modules/mob/living/basic/space_fauna/ghost.dm @@ -22,7 +22,7 @@ attack_sound = 'sound/hallucinations/growl1.ogg' death_message = "wails, disintegrating into a pile of ectoplasm!" gold_core_spawnable = NO_SPAWN //too spooky for science - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 1 // same glowing as visible player ghosts light_power = 2 ai_controller = /datum/ai_controller/basic_controller/ghost diff --git a/code/modules/mob/living/silicon/robot/robot_defines.dm b/code/modules/mob/living/silicon/robot/robot_defines.dm index 965845073cd..d0c47141ffe 100644 --- a/code/modules/mob/living/silicon/robot/robot_defines.dm +++ b/code/modules/mob/living/silicon/robot/robot_defines.dm @@ -23,7 +23,7 @@ radio = /obj/item/radio/borg blocks_emissive = EMISSIVE_BLOCK_UNIQUE - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_on = FALSE diff --git a/code/modules/mob/living/simple_animal/bot/bot.dm b/code/modules/mob/living/simple_animal/bot/bot.dm index 22c7439ec80..ff304332c8d 100644 --- a/code/modules/mob/living/simple_animal/bot/bot.dm +++ b/code/modules/mob/living/simple_animal/bot/bot.dm @@ -23,7 +23,7 @@ bubble_icon = "machine" speech_span = SPAN_ROBOT faction = list(FACTION_NEUTRAL, FACTION_SILICON, FACTION_TURRET) - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 3 light_power = 0.9 del_on_death = TRUE diff --git a/code/modules/mob/living/simple_animal/bot/vibebot.dm b/code/modules/mob/living/simple_animal/bot/vibebot.dm index 5a876bd8eca..d0d550f7737 100644 --- a/code/modules/mob/living/simple_animal/bot/vibebot.dm +++ b/code/modules/mob/living/simple_animal/bot/vibebot.dm @@ -9,7 +9,7 @@ health = 25 maxHealth = 25 pass_flags = PASSMOB | PASSFLAPS - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 7 light_power = 3 diff --git a/code/modules/mob/living/simple_animal/hostile/megafauna/colossus.dm b/code/modules/mob/living/simple_animal/hostile/megafauna/colossus.dm index e256e4f2921..9253448563b 100644 --- a/code/modules/mob/living/simple_animal/hostile/megafauna/colossus.dm +++ b/code/modules/mob/living/simple_animal/hostile/megafauna/colossus.dm @@ -165,7 +165,7 @@ icon_state = "at_shield2" layer = FLY_LAYER plane = ABOVE_GAME_PLANE - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 2 duration = 8 var/target diff --git a/code/modules/mod/mod_construction.dm b/code/modules/mod/mod_construction.dm index fdbcf47d379..8442783d331 100644 --- a/code/modules/mod/mod_construction.dm +++ b/code/modules/mod/mod_construction.dm @@ -58,7 +58,7 @@ icon_state = "plasma-flower" desc = "A strange flower from the desolate wastes of lavaland. It pulses with a bright purple glow. \ Its shape is remarkably similar to that of a MOD core." - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_color = "#cc00cc" light_range = 2 diff --git a/code/modules/mod/mod_core.dm b/code/modules/mod/mod_core.dm index d5c43497982..75a5b2385b7 100644 --- a/code/modules/mod/mod_core.dm +++ b/code/modules/mod/mod_core.dm @@ -367,7 +367,7 @@ icon_state = "mod-core-plasma-flower" desc = "A strange flower from the desolate wastes of lavaland. It pulses with a strange purple glow. \ The wires coming out of it could be hooked into a MODsuit." - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_color = "#cc00cc" light_range = 2 // Slightly better than the normal plasma core. diff --git a/code/modules/mod/modules/modules_general.dm b/code/modules/mod/modules/modules_general.dm index 354d5564b10..9962bc8b9a4 100644 --- a/code/modules/mod/modules/modules_general.dm +++ b/code/modules/mod/modules/modules_general.dm @@ -365,7 +365,7 @@ incompatible_modules = list(/obj/item/mod/module/flashlight) cooldown_time = 0.5 SECONDS overlay_state_inactive = "module_light" - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_color = COLOR_WHITE light_range = 4 light_power = 1 diff --git a/code/modules/mod/modules/modules_supply.dm b/code/modules/mod/modules/modules_supply.dm index 15f2a543239..7fd9db2ce3b 100644 --- a/code/modules/mod/modules/modules_supply.dm +++ b/code/modules/mod/modules/modules_supply.dm @@ -568,7 +568,7 @@ range = 6 suppressed = SUPPRESSED_VERY armor_flag = BOMB - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 1 light_power = 1 light_color = COLOR_LIGHT_ORANGE @@ -590,7 +590,7 @@ icon = 'icons/obj/clothing/modsuit/mod_modules.dmi' anchored = TRUE resistance_flags = FIRE_PROOF|LAVA_PROOF - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 1 light_power = 1 light_color = COLOR_LIGHT_ORANGE diff --git a/code/modules/modular_computers/computers/item/computer.dm b/code/modules/modular_computers/computers/item/computer.dm index 7a30a20d104..fd689c3bc16 100644 --- a/code/modules/modular_computers/computers/item/computer.dm +++ b/code/modules/modular_computers/computers/item/computer.dm @@ -10,7 +10,7 @@ integrity_failure = 0.5 max_integrity = 100 armor_type = /datum/armor/item_modular_computer - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL ///The ID currently stored in the computer. var/obj/item/card/id/computer_id_slot diff --git a/code/modules/pai/pai.dm b/code/modules/pai/pai.dm index 52c4534d4fa..81627021583 100644 --- a/code/modules/pai/pai.dm +++ b/code/modules/pai/pai.dm @@ -16,7 +16,7 @@ light_flags = LIGHT_ATTACHED light_on = FALSE light_range = 3 - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT maxHealth = 500 mob_size = MOB_SIZE_TINY mobility_flags = MOBILITY_FLAGS_REST_CAPABLE_DEFAULT diff --git a/code/modules/paperwork/pen.dm b/code/modules/paperwork/pen.dm index 5ee432b365e..10a15e88196 100644 --- a/code/modules/paperwork/pen.dm +++ b/code/modules/paperwork/pen.dm @@ -325,7 +325,7 @@ armour_penetration = 20 bare_wound_bonus = 10 item_flags = NO_BLOOD_ON_ITEM - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 1.5 light_power = 0.75 light_color = COLOR_SOFT_RED diff --git a/code/modules/photography/camera/camera.dm b/code/modules/photography/camera/camera.dm index dae12f33bd4..3f721c1cefc 100644 --- a/code/modules/photography/camera/camera.dm +++ b/code/modules/photography/camera/camera.dm @@ -10,7 +10,7 @@ worn_icon_state = "camera" lefthand_file = 'icons/mob/inhands/items/devices_lefthand.dmi' righthand_file = 'icons/mob/inhands/items/devices_righthand.dmi' - light_system = MOVABLE_LIGHT //Used as a flash here. + light_system = OVERLAY_LIGHT //Used as a flash here. light_range = 8 light_color = COLOR_WHITE light_power = FLASH_LIGHT_POWER diff --git a/code/modules/projectiles/projectile/beams.dm b/code/modules/projectiles/projectile/beams.dm index d3f13f4bdbe..5845ac0c990 100644 --- a/code/modules/projectiles/projectile/beams.dm +++ b/code/modules/projectiles/projectile/beams.dm @@ -9,7 +9,7 @@ armor_flag = LASER eyeblur = 4 SECONDS impact_effect_type = /obj/effect/temp_visual/impact_effect/red_laser - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 1 light_power = 1 light_color = COLOR_SOFT_RED diff --git a/code/modules/research/ordnance/doppler_array.dm b/code/modules/research/ordnance/doppler_array.dm index a109e5061df..32495e93020 100644 --- a/code/modules/research/ordnance/doppler_array.dm +++ b/code/modules/research/ordnance/doppler_array.dm @@ -18,7 +18,7 @@ var/obj/item/computer_disk/inserted_disk // Lighting system to better communicate the directions. - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_range = 4 light_power = 1 light_color = COLOR_RED diff --git a/code/modules/surgery/tools.dm b/code/modules/surgery/tools.dm index 571e8c422d9..fee7f389dca 100644 --- a/code/modules/surgery/tools.dm +++ b/code/modules/surgery/tools.dm @@ -93,7 +93,7 @@ hitsound = 'sound/items/welder.ogg' w_class = WEIGHT_CLASS_NORMAL toolspeed = 0.7 - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 1 light_color = COLOR_SOFT_RED @@ -378,7 +378,7 @@ force = 16 w_class = WEIGHT_CLASS_NORMAL toolspeed = 0.7 - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 1 light_color = LIGHT_COLOR_BLUE sharpness = SHARP_EDGED diff --git a/code/modules/vehicles/cars/clowncar.dm b/code/modules/vehicles/cars/clowncar.dm index d5a3d7bdc7d..032a054a77c 100644 --- a/code/modules/vehicles/cars/clowncar.dm +++ b/code/modules/vehicles/cars/clowncar.dm @@ -9,7 +9,7 @@ movedelay = 0.6 car_traits = CAN_KIDNAP key_type = /obj/item/bikehorn - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_range = 8 light_power = 2 light_on = FALSE diff --git a/code/modules/vehicles/cars/vim.dm b/code/modules/vehicles/cars/vim.dm index a37c6e18b8e..53eee5105a9 100644 --- a/code/modules/vehicles/cars/vim.dm +++ b/code/modules/vehicles/cars/vim.dm @@ -13,7 +13,7 @@ enter_delay = 20 movedelay = 0.6 engine_sound_length = 0.3 SECONDS - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_range = 4 light_power = 2 light_on = FALSE diff --git a/code/modules/vehicles/mecha/_mecha.dm b/code/modules/vehicles/mecha/_mecha.dm index dc7304a1388..05b3470358f 100644 --- a/code/modules/vehicles/mecha/_mecha.dm +++ b/code/modules/vehicles/mecha/_mecha.dm @@ -29,7 +29,7 @@ move_force = MOVE_FORCE_VERY_STRONG move_resist = MOVE_FORCE_EXTREMELY_STRONG COOLDOWN_DECLARE(mecha_bump_smash) - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_on = FALSE light_range = 8 generic_canpass = FALSE diff --git a/code/modules/vehicles/mecha/combat/durand.dm b/code/modules/vehicles/mecha/combat/durand.dm index f1c7bac4f81..35b53c30ccf 100644 --- a/code/modules/vehicles/mecha/combat/durand.dm +++ b/code/modules/vehicles/mecha/combat/durand.dm @@ -164,7 +164,7 @@ own integrity back to max. Shield is automatically dropped if we run out of powe pixel_y = 4 max_integrity = 10000 anchored = TRUE - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = MINIMUM_USEFUL_LIGHT_RANGE light_power = 5 light_color = LIGHT_COLOR_ELECTRIC_CYAN diff --git a/code/modules/wiremod/shell/bot.dm b/code/modules/wiremod/shell/bot.dm index dfd9845bc05..533c654e787 100644 --- a/code/modules/wiremod/shell/bot.dm +++ b/code/modules/wiremod/shell/bot.dm @@ -9,7 +9,7 @@ icon_state = "setup_medium_box" density = FALSE - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_on = FALSE /obj/structure/bot/Initialize(mapload) diff --git a/code/modules/wiremod/shell/compact_remote.dm b/code/modules/wiremod/shell/compact_remote.dm index 38fdfccf951..3336be06ddb 100644 --- a/code/modules/wiremod/shell/compact_remote.dm +++ b/code/modules/wiremod/shell/compact_remote.dm @@ -11,7 +11,7 @@ worn_icon_state = "electronic" lefthand_file = 'icons/mob/inhands/items/devices_lefthand.dmi' righthand_file = 'icons/mob/inhands/items/devices_righthand.dmi' - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_on = FALSE /obj/item/compact_remote/Initialize(mapload) diff --git a/code/modules/wiremod/shell/controller.dm b/code/modules/wiremod/shell/controller.dm index 3092d3315f1..ad03867b89b 100644 --- a/code/modules/wiremod/shell/controller.dm +++ b/code/modules/wiremod/shell/controller.dm @@ -12,7 +12,7 @@ worn_icon_state = "electronic" lefthand_file = 'icons/mob/inhands/items/devices_lefthand.dmi' righthand_file = 'icons/mob/inhands/items/devices_righthand.dmi' - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_on = FALSE /obj/item/controller/Initialize(mapload) diff --git a/code/modules/wiremod/shell/dispenser.dm b/code/modules/wiremod/shell/dispenser.dm index 5fa2d2b1a8e..4ea2d03c9d7 100644 --- a/code/modules/wiremod/shell/dispenser.dm +++ b/code/modules/wiremod/shell/dispenser.dm @@ -9,7 +9,7 @@ icon_state = "setup_drone_arms" density = FALSE - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_on = FALSE var/max_weight = WEIGHT_CLASS_NORMAL diff --git a/code/modules/wiremod/shell/drone.dm b/code/modules/wiremod/shell/drone.dm index 6f7afcfea04..96fe3b2fa0a 100644 --- a/code/modules/wiremod/shell/drone.dm +++ b/code/modules/wiremod/shell/drone.dm @@ -10,7 +10,7 @@ maxHealth = 300 health = 300 living_flags = 0 - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_on = FALSE /mob/living/circuit_drone/Initialize(mapload) diff --git a/code/modules/wiremod/shell/gun.dm b/code/modules/wiremod/shell/gun.dm index e9176d8c6ca..3a37501e8e1 100644 --- a/code/modules/wiremod/shell/gun.dm +++ b/code/modules/wiremod/shell/gun.dm @@ -11,7 +11,7 @@ ammo_type = list(/obj/item/ammo_casing/energy/wiremod_gun) cell_type = /obj/item/stock_parts/cell/emproof/wiremod_gun item_flags = NONE - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_on = FALSE automatic_charge_overlays = FALSE trigger_guard = TRIGGER_GUARD_ALLOW_ALL diff --git a/code/modules/wiremod/shell/keyboard.dm b/code/modules/wiremod/shell/keyboard.dm index 05b9ded074b..0b28959aa9c 100644 --- a/code/modules/wiremod/shell/keyboard.dm +++ b/code/modules/wiremod/shell/keyboard.dm @@ -6,7 +6,7 @@ worn_icon_state = "electronic" lefthand_file = 'icons/mob/inhands/items/devices_lefthand.dmi' righthand_file = 'icons/mob/inhands/items/devices_righthand.dmi' - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_on = FALSE /obj/item/keyboard_shell/Initialize(mapload) diff --git a/code/modules/wiremod/shell/moneybot.dm b/code/modules/wiremod/shell/moneybot.dm index 20eb596eb72..cacb457149d 100644 --- a/code/modules/wiremod/shell/moneybot.dm +++ b/code/modules/wiremod/shell/moneybot.dm @@ -9,7 +9,7 @@ icon_state = "setup_large" density = FALSE - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_on = FALSE var/stored_money = 0 diff --git a/code/modules/wiremod/shell/scanner.dm b/code/modules/wiremod/shell/scanner.dm index 3012fe65e49..c88d7b1fb5f 100644 --- a/code/modules/wiremod/shell/scanner.dm +++ b/code/modules/wiremod/shell/scanner.dm @@ -11,7 +11,7 @@ worn_icon_state = "electronic" lefthand_file = 'icons/mob/inhands/items/devices_lefthand.dmi' righthand_file = 'icons/mob/inhands/items/devices_righthand.dmi' - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_on = FALSE /obj/item/wiremod_scanner/Initialize(mapload) diff --git a/code/modules/wiremod/shell/server.dm b/code/modules/wiremod/shell/server.dm index fc71bfaa265..24501797197 100644 --- a/code/modules/wiremod/shell/server.dm +++ b/code/modules/wiremod/shell/server.dm @@ -10,7 +10,7 @@ icon_state = "setup_stationary" density = TRUE - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_on = FALSE /obj/structure/server/Initialize(mapload) diff --git a/modular_skyrat/master_files/code/modules/mob/living/simple_animal/friendly/dogs.dm b/modular_skyrat/master_files/code/modules/mob/living/simple_animal/friendly/dogs.dm index 27d1aabb67b..ba370f99d6b 100644 --- a/modular_skyrat/master_files/code/modules/mob/living/simple_animal/friendly/dogs.dm +++ b/modular_skyrat/master_files/code/modules/mob/living/simple_animal/friendly/dogs.dm @@ -86,7 +86,7 @@ can_breed = FALSE // These lights enable when E-N is emagged - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_color = COLOR_RED light_range = 2 light_power = 0.8 diff --git a/modular_skyrat/master_files/code/modules/mob/living/simple_animal/friendly/poppy.dm b/modular_skyrat/master_files/code/modules/mob/living/simple_animal/friendly/poppy.dm index 37829815def..a3060c87849 100644 --- a/modular_skyrat/master_files/code/modules/mob/living/simple_animal/friendly/poppy.dm +++ b/modular_skyrat/master_files/code/modules/mob/living/simple_animal/friendly/poppy.dm @@ -34,7 +34,7 @@ mob_size = MOB_SIZE_TINY mob_biotypes = MOB_ORGANIC|MOB_BEAST gold_core_spawnable = NO_SPAWN - light_system = MOVABLE_LIGHT_DIRECTIONAL + light_system = OVERLAY_LIGHT_DIRECTIONAL light_color = LIGHT_COLOR_BRIGHT_YELLOW light_range = 2 light_power = 0.8 diff --git a/modular_skyrat/modules/energy_axe/code/energy_fireaxe.dm b/modular_skyrat/modules/energy_axe/code/energy_fireaxe.dm index a956ebce1bf..19f4de36d63 100644 --- a/modular_skyrat/modules/energy_axe/code/energy_fireaxe.dm +++ b/modular_skyrat/modules/energy_axe/code/energy_fireaxe.dm @@ -12,7 +12,7 @@ desc = "You aren't quite sure if this counts as a fire axe anymore, but it sure is fancy! A tag hangs off of it reading: \"property of the Gorlex Marauders\"" force = 5 throwforce = 15 - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 6 light_color = COLOR_SOFT_RED light_on = FALSE diff --git a/modular_skyrat/modules/modular_items/lewd_items/code/lewd_items/shibari.dm b/modular_skyrat/modules/modular_items/lewd_items/code/lewd_items/shibari.dm index 612ed54be96..38b2736db42 100644 --- a/modular_skyrat/modules/modular_items/lewd_items/code/lewd_items/shibari.dm +++ b/modular_skyrat/modules/modular_items/lewd_items/code/lewd_items/shibari.dm @@ -41,7 +41,7 @@ singular_name = "glowy rope" merge_type = /obj/item/stack/shibari_rope/glow icon_state = "shibari_rope_glow" - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 1 light_on = TRUE light_power = 3 diff --git a/modular_skyrat/modules/modular_items/lewd_items/code/lewd_structures/dancing_pole.dm b/modular_skyrat/modules/modular_items/lewd_items/code/lewd_structures/dancing_pole.dm index 202e20f7353..e88b76206b9 100644 --- a/modular_skyrat/modules/modular_items/lewd_items/code/lewd_structures/dancing_pole.dm +++ b/modular_skyrat/modules/modular_items/lewd_items/code/lewd_structures/dancing_pole.dm @@ -10,7 +10,7 @@ layer = BELOW_MOB_LAYER pseudo_z_axis = 9 //stepping onto the pole makes you raise upwards! density = 0 //easy to step up on - light_system = STATIC_LIGHT + light_system = COMPLEX_LIGHT light_range = 3 light_power = 1 light_color = COLOR_LIGHT_PINK diff --git a/modular_skyrat/modules/modular_weapons/code/ballistic_master.dm b/modular_skyrat/modules/modular_weapons/code/ballistic_master.dm index 1f6a0f2111c..97353b6c304 100644 --- a/modular_skyrat/modules/modular_weapons/code/ballistic_master.dm +++ b/modular_skyrat/modules/modular_weapons/code/ballistic_master.dm @@ -71,7 +71,7 @@ to_chat(user, span_notice("You load [num_loaded] [cartridge_wording]\s into [src][box_load ? ", but it takes some extra effort" : ""].")) /obj/effect/temp_visual/dir_setting/firing_effect - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 2 light_power = 1 light_color = LIGHT_COLOR_FIRE diff --git a/modular_skyrat/modules/mold/code/mold_mobs.dm b/modular_skyrat/modules/mold/code/mold_mobs.dm index 6c1bd7be019..44a3d4bbb75 100644 --- a/modular_skyrat/modules/mold/code/mold_mobs.dm +++ b/modular_skyrat/modules/mold/code/mold_mobs.dm @@ -48,7 +48,7 @@ gold_core_spawnable = HOSTILE_SPAWN death_message = "evaporates!" - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_color = LIGHT_COLOR_FIRE light_range = 2 light_power = 1 @@ -252,7 +252,7 @@ obj_damage = 40 attack_sound = 'sound/effects/wounds/crackandbleed.ogg' - light_system = MOVABLE_LIGHT + light_system = OVERLAY_LIGHT light_range = 2 light_power = 1 light_color = LIGHT_COLOR_GREEN