From 2efeabbbf15df93b194fb6ec38fb400d013fd74c Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Sat, 1 Apr 2023 09:20:27 +0200 Subject: [PATCH] [MIRROR] Fixes the emissive blockers from the body parts layering over everything [MDB IGNORE] (#20244) * Fixes the emissive blockers from the body parts layering over everything (#74362) ## About The Pull Request As it says, this PR will stop bodypart emissive blockers from layering over all the things. This will fix any emissives that were not displaying on clothing, such as the safety vest. Fixes https://github.com/Skyrat-SS13/Skyrat-tg/issues/19531 https://github.com/tgstation/tgstation/issues/62442 and https://github.com/tgstation/tgstation/issues/64098 are not fixed by this, these are separate issues. ## Why It's Good For The Game The pretty lights return to dazzle us once more.
Safety vest emissives ![dreamseeker_6vwaJOkpHR](https://user-images.githubusercontent.com/13398309/228765863-0ef65eff-60c9-496d-b289-6723716d1b2c.gif)
## Changelog :cl: fix: fixes emissives blocker layering issue that was causing emissives on clothing to not display at all /:cl: Lemon: I am curious about when this became an issue, since it seems inconsistent with what I'd expect I know this was working last year, around early fall, from screenshots. But beyond that, no clue. It happened sometime between now and then. FLOAT_LAYER is very untrustworthy, I wish Lummox would add some debugging var that shows the last layer it was rendered on or something because there is really no way to see what it's doing reliably. But for now explicitly setting the layer might be a good idea for stuff like this. * Fixes the emissive blockers from the body parts layering over everything --------- Co-authored-by: Bloop --- code/modules/surgery/bodyparts/_bodyparts.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/modules/surgery/bodyparts/_bodyparts.dm b/code/modules/surgery/bodyparts/_bodyparts.dm index f3cde8cfb3f..ffb7c615305 100644 --- a/code/modules/surgery/bodyparts/_bodyparts.dm +++ b/code/modules/surgery/bodyparts/_bodyparts.dm @@ -932,12 +932,12 @@ // to be able to mask it proper in case this limb is a leg. if(blocks_emissive) var/atom/location = loc || owner || src - var/mutable_appearance/limb_em_block = emissive_blocker(limb.icon, limb.icon_state, location, alpha = limb.alpha) + var/mutable_appearance/limb_em_block = emissive_blocker(limb.icon, limb.icon_state, location, layer = limb.layer, alpha = limb.alpha) limb_em_block.dir = image_dir . += limb_em_block if(aux_zone) - var/mutable_appearance/aux_em_block = emissive_blocker(aux.icon, aux.icon_state, location, alpha = aux.alpha) + var/mutable_appearance/aux_em_block = emissive_blocker(aux.icon, aux.icon_state, location, layer = aux.layer, alpha = aux.alpha) aux_em_block.dir = image_dir . += aux_em_block //EMISSIVE CODE END