diff --git a/tools/quake3/q3map2/light.cpp b/tools/quake3/q3map2/light.cpp index 98ece513..6d8a4517 100644 --- a/tools/quake3/q3map2/light.cpp +++ b/tools/quake3/q3map2/light.cpp @@ -1939,7 +1939,7 @@ static void LightWorld( bool fastAllocate ){ SetupEnvelopes( false, fastbounce ); if ( lights.empty() ) { Sys_Printf( "No diffuse light to calculate, ending radiosity.\n" ); - break; + return; } /* add to lightgrid */ @@ -1982,6 +1982,8 @@ static void LightWorld( bool fastAllocate ){ bounce--; b++; } + /* ydnar: store off lightmaps */ + StoreSurfaceLightmaps( fastAllocate ); } @@ -2814,9 +2816,6 @@ int LightMain( Args& args ){ /* light the world */ LightWorld( fastAllocate ); - /* ydnar: store off lightmaps */ - StoreSurfaceLightmaps( fastAllocate ); - /* write out the bsp */ UnparseEntities(); Sys_Printf( "Writing %s\n", source );