]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - gl_rmain.c
merged R_DrawWorld into DrawSky/Draw so that rmain can just call DrawSky and Draw...
[xonotic/darkplaces.git] / gl_rmain.c
index 76123a6f450eaef7107c413eba6259f4a22fc77f..fad13e4ce3bc53f32dfb42e906160cc0f75c3ae2 100644 (file)
@@ -688,12 +688,22 @@ void R_RenderScene(void)
        if (!intimerefresh && !r_speeds.integer)
                S_ExtraUpdate ();
 
+       GL_ShowTrisColor(0.025, 0.025, 0, 1);
+       if (world->model && world->model->DrawSky)
+       {
+               world->model->DrawSky(world);
+               R_TimeReport("worldsky");
+       }
+
        if (R_DrawBrushModelsSky())
                R_TimeReport("bmodelsky");
 
-       // must occur early because it can draw sky
-       R_DrawWorld(world);
-       R_TimeReport("world");
+       GL_ShowTrisColor(0.05, 0.05, 0.05, 1);
+       if (world->model && world->model->Draw)
+       {
+               world->model->Draw(world);
+               R_TimeReport("world");
+       }
 
        // don't let sound skip if going slow
        if (!intimerefresh && !r_speeds.integer)