From 10a80d15198ef02db4b26aaf1e55ddd511072779 Mon Sep 17 00:00:00 2001 From: seedee Date: Wed, 10 Jul 2024 23:30:55 +0100 Subject: [PATCH] Add % fullbright lightmapped texture flag --- src/sdhlt/sdHLRAD/lightmap.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/sdhlt/sdHLRAD/lightmap.cpp b/src/sdhlt/sdHLRAD/lightmap.cpp index f8873c0d..8f4e0493 100644 --- a/src/sdhlt/sdHLRAD/lightmap.cpp +++ b/src/sdhlt/sdHLRAD/lightmap.cpp @@ -4871,7 +4871,6 @@ void FinalLightFace(const int facenum) return; // non-lit texture } - for (lightstyles = 0; lightstyles < MAXLIGHTMAPS; lightstyles++) { if (f->styles[lightstyles] == 255) @@ -4893,6 +4892,11 @@ void FinalLightFace(const int facenum) // minlight = FloatForKey(g_face_entity[facenum], "_minlight") * 128; + if (!strncasecmp(GetTextureByNumber(f->texinfo), "%", 1)) //If texture name has % flag //seedee + { + minlight = 2 * 128; //max _minlight * 128 = fullbright + } + original_basiclight = (vec3_t *)calloc (fl->numsamples, sizeof(vec3_t)); final_basiclight = (int (*)[3])calloc (fl->numsamples, sizeof(int [3])); hlassume (original_basiclight != NULL, assume_NoMemory);