]> git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
don't error out if external lightmap sizes mismatch, just print a
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 18 Feb 2010 12:11:48 +0000 (12:11 +0000)
committerRudolf Polzer <rpolzer@grawp.div0.qc.to>
Mon, 22 Feb 2010 17:28:16 +0000 (18:28 +0100)
warning and ignore the mismatching one and any later ones

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@9986 d7cf8633-e32d-0410-b094-e92efae38249
::stable-branch::merge=6a62eaee164fc07bb7829eaf44d1ea064a72e6ec

model_brush.c

index 459300bd53ca0f6ab196dfa7c3fd7335b976f5a0..1f382f92fcfcddc90b72f77d45ff4335ddb841ab 100644 (file)
@@ -4596,9 +4596,10 @@ static void Mod_Q3BSP_LoadLightmaps(lump_t *l, lump_t *faceslump)
                                break; // we got all of them
                        if(image_width != size || image_height != size)
                        {
-                               for(i = 0; i <= count; ++i)
-                                       Mem_Free(inpixels[i]);
-                               Host_Error("Mod_Q3BSP_LoadLightmaps: invalid external lightmap size in %s",loadmodel->name);
+                               Mem_Free(inpixels[count]);
+                               inpixels[count] = NULL;
+                               Con_Printf("Mod_Q3BSP_LoadLightmaps: mismatched lightmap size in %s - external lightmap %s/lm_%04d does not match earlier ones\n", loadmodel->name, mapname, count);
+                               break;
                        }
                }
        }