From abd62dd834aff81f213b3537f2a1a1703e44fe21 Mon Sep 17 00:00:00 2001 From: phobos2077 Date: Thu, 27 Jun 2024 23:25:25 +0200 Subject: [PATCH] gl_highlighting: separate colors for containers and corpses - Items and corpses blending together can be an issue --- artifacts/config_files/sfall-mods.ini | 8 +++++++- artifacts/mods/gl_highlighting.int | Bin 4942 -> 5238 bytes artifacts/mods/gl_highlighting.ssl | 13 ++++++++++++- 3 files changed, 19 insertions(+), 2 deletions(-) diff --git a/artifacts/config_files/sfall-mods.ini b/artifacts/config_files/sfall-mods.ini index ec6a99de7..5868185ba 100644 --- a/artifacts/config_files/sfall-mods.ini +++ b/artifacts/config_files/sfall-mods.ini @@ -15,7 +15,7 @@ Critters=0 ; Set to 1 to only highlight objects in the player's line-of-sight CheckLOS=1 -; Set the color of outlines for items, corpses, and containers; available colors: +; Set the color of outlines for items; available colors: ; 1 - glowing red ; 2 - red ; 4 - grey @@ -26,6 +26,12 @@ CheckLOS=1 ; You can set a custom color from the game palette by multiplying the color index value by 256 (in 4.2.7 or later) OutlineColor=16 +; Set the color of outlines for corpses +OutlineColorCorpses=4 + +; Set the color of outlines for containers +OutlineColorContainers=4 + ; Motion Scanner mode: ; 0 - ignored ; 1 - requires Motion Sensor to be present in the player's inventory to activate highlighting diff --git a/artifacts/mods/gl_highlighting.int b/artifacts/mods/gl_highlighting.int index 138e3b527d4d5e786880350c1c77c54757361295..11091da72d5b6b8c4b97866c6b57969d6229d069 100644 GIT binary patch delta 1699 zcmZuxU1(HC6rP#gyLBd5i@j8+F-`oKvkl3pLtm-G65Z52g;*8AU9bMolfHpm%2v>-h2WJ2_I8V}8c|92Z+OYr+JM{o7UlOLZs_2I;c;mK2z_2J3->8TS_ zgltNq6K9S|N_`3rvnTZC5BoC#?Tz=n)G>{=9LKYNL6_m0BBQQ0tidj0gyqU0j14ST zf-j9v>5tHzJ6+6I6oD{NMoGjQqEnsnW%w@l4*eXS<<2sb!P)$~bOP??kA)LRq@pbP z)X97ZL*}4q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vw8w8xlsgOF SWwen_Sd3;#4-+uzH2eiMn--7& diff --git a/artifacts/mods/gl_highlighting.ssl b/artifacts/mods/gl_highlighting.ssl index 6b0b2871b..e4fc73dac 100644 --- a/artifacts/mods/gl_highlighting.ssl +++ b/artifacts/mods/gl_highlighting.ssl @@ -15,7 +15,7 @@ NOTE: this script requires compiler from sfall modderspack with -s option (short circuit evaluation) - version 1.2 + version 1.3 **/ @@ -36,6 +36,8 @@ variable alsoCorpse; variable alsoCritter; variable checkLOS; variable outlineColor; +variable outlineColorCorpses; +variable outlineColorContainers; variable motionScanner; variable highlightFailMsg1; variable highlightFailMsg2; @@ -65,6 +67,12 @@ procedure GetOutlineColor(variable obj, variable isCritter) begin if checkLOS and not DudeCanSee(obj) then return 0; + if obj_type(obj) == OBJ_TYPE_CRITTER then + return outlineColorCorpses; + + if obj_item_subtype(obj) == item_type_container then + return outlineColorContainers; + return outlineColor; end @@ -165,6 +173,9 @@ procedure start begin alsoCritter := GetConfig(configSection, "Critters", 0); checkLOS := GetConfig(configSection, "CheckLOS", 0); outlineColor := GetConfig(configSection, "OutlineColor", 16); + outlineColorCorpses := GetConfig(configSection, "OutlineColorCorpses", 16); + outlineColorContainers := GetConfig(configSection, "OutlineColorContainers", 16); + if (outlineColor < 1) then outlineColor := 64; motionScanner := GetConfig(configSection, "MotionScanner", 0);