]> git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
fix saving of rtlights files (everything past cubemap was getting lost)
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Tue, 9 Mar 2004 04:56:04 +0000 (04:56 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Tue, 9 Mar 2004 04:56:04 +0000 (04:56 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@3981 d7cf8633-e32d-0410-b094-e92efae38249

r_shadow.c

index 5b5d53fda680b41caa795429b935a65b064aa4da..58f203e6f11d27f2186dd79fc63bc397706e0593 100644 (file)
@@ -2461,6 +2461,22 @@ void R_Shadow_LoadWorldLights(void)
                n = 0;
                while (*s)
                {
+                       t = s;
+                       /*
+                       shadow = true;
+                       for (;COM_Parse(t, true) && strcmp(
+                       if (COM_Parse(t, true))
+                       {
+                               if (com_token[0] == '!')
+                               {
+                                       shadow = false;
+                                       origin[0] = atof(com_token+1);
+                               }
+                               else
+                                       origin[0] = atof(com_token);
+                               if (Com_Parse(t
+                       }
+                       */
                        t = s;
                        while (*s && *s != '\n')
                                s++;
@@ -2519,7 +2535,7 @@ void R_Shadow_SaveWorldLights(void)
        buf = NULL;
        for (light = r_shadow_worldlightchain;light;light = light->next)
        {
-               sprintf(line, "%s%f %f %f %f %f %f %f %d %s %f %f %f %f\n", light->shadow ? "" : "!", light->origin[0], light->origin[1], light->origin[2], light->radius / r_editlights_rtlightssizescale.value, light->color[0] / r_editlights_rtlightscolorscale.value, light->color[1] / r_editlights_rtlightscolorscale.value, light->color[2] / r_editlights_rtlightscolorscale.value, light->style, light->cubemapname ? light->cubemapname : "\"\"", light->corona, light->angles[0], light->angles[1], light->angles[2]);
+               sprintf(line, "%s%f %f %f %f %f %f %f %d %s %f %f %f %f\n", light->shadow ? "" : "!", light->origin[0], light->origin[1], light->origin[2], light->radius / r_editlights_rtlightssizescale.value, light->color[0] / r_editlights_rtlightscolorscale.value, light->color[1] / r_editlights_rtlightscolorscale.value, light->color[2] / r_editlights_rtlightscolorscale.value, light->style, light->cubemapname[0] ? light->cubemapname : "\"\"", light->corona, light->angles[0], light->angles[1], light->angles[2]);
                if (bufchars + (int) strlen(line) > bufmaxchars)
                {
                        bufmaxchars = bufchars + strlen(line) + 2048;