Always initialize numLightmaps when loading lightmaps

This fixes an issue where the number of lightmaps is kept from the previous map if the new map has no lightmaps
This commit is contained in:
smallmodel 2025-01-19 15:19:27 +01:00 committed by GitHub
parent c2bac6d1ef
commit 7452bf39fb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -199,6 +199,8 @@ static void R_LoadLightmaps(gamelump_t* l) {
float maxIntensity = 0;
double sumIntensity = 0;
tr.numLightmaps = 0;
len = l->length;
if (!len) {
return;