mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-01-18 15:01:41 +00:00
Fix a new bug with dlights, more cleanups.
This commit is contained in:
parent
048a80ce23
commit
924cdf917d
6 changed files with 32 additions and 17 deletions
|
@ -187,6 +187,22 @@ CL_ClearState (void)
|
|||
}
|
||||
|
||||
|
||||
/*
|
||||
CL_StopCshifts
|
||||
|
||||
Cleans the Cshifts, so your screen doesn't stay red after a timedemo :)
|
||||
*/
|
||||
void
|
||||
CL_StopCshifts (void)
|
||||
{
|
||||
int i;
|
||||
for (i = 0; i < NUM_CSHIFTS; i++)
|
||||
cl.cshifts[i].percent = 0;
|
||||
for (i = 0; i < MAX_CL_STATS; i++)
|
||||
cl.stats[i] = 0;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
CL_Disconnect
|
||||
|
||||
|
@ -196,13 +212,16 @@ CL_ClearState (void)
|
|||
void
|
||||
CL_Disconnect (void)
|
||||
{
|
||||
// stop sounds (especially looping!)
|
||||
// stop sounds (especially looping!)
|
||||
S_StopAllSounds (true);
|
||||
|
||||
// bring the console down and fade the colors back to normal
|
||||
// SCR_BringDownConsole ();
|
||||
// Clean the Cshifts
|
||||
CL_StopCshifts ();
|
||||
|
||||
// if running a local server, shut it down
|
||||
// bring the console down and fade the colors back to normal
|
||||
// SCR_BringDownConsole ();
|
||||
|
||||
// if running a local server, shut it down
|
||||
if (cls.demoplayback)
|
||||
CL_StopPlayback ();
|
||||
else if (cls.state == ca_connected) {
|
||||
|
|
|
@ -888,6 +888,8 @@ R_RenderView (void)
|
|||
|
||||
R_SetupGL ();
|
||||
|
||||
R_PushDlights (vec3_origin);
|
||||
|
||||
R_MarkLeaves (); // done here so we know if we're in water
|
||||
|
||||
R_DrawWorld (); // adds static entities to the list
|
||||
|
|
|
@ -690,9 +690,6 @@ V_RenderView (void)
|
|||
V_CalcRefdef ();
|
||||
}
|
||||
|
||||
// nq thinks dlights should be here
|
||||
R_PushDlights (vec3_origin);
|
||||
|
||||
R_RenderView ();
|
||||
}
|
||||
|
||||
|
|
|
@ -471,13 +471,13 @@ CL_Disconnect (void)
|
|||
|
||||
VID_SetCaption ("Disconnected");
|
||||
|
||||
// stop sounds (especially looping!)
|
||||
// stop sounds (especially looping!)
|
||||
S_StopAllSounds (true);
|
||||
|
||||
// Clean the Cshifts
|
||||
// Clean the Cshifts
|
||||
CL_StopCshifts ();
|
||||
|
||||
// if running a local server, shut it down
|
||||
// if running a local server, shut it down
|
||||
if (cls.demoplayback)
|
||||
CL_StopPlayback ();
|
||||
else if (cls.state != ca_disconnected) {
|
||||
|
|
|
@ -67,7 +67,6 @@
|
|||
#include "sbar.h"
|
||||
#include "view.h"
|
||||
|
||||
extern cvar_t *gl_dlight_polyblend;
|
||||
extern cvar_t *cl_autoexec;
|
||||
|
||||
char *svc_strings[] = {
|
||||
|
|
|
@ -1073,7 +1073,7 @@ R_RenderView (void)
|
|||
R_Clear ();
|
||||
|
||||
// render normal view
|
||||
R_SetupFrame (); // Setup stuff for frame.
|
||||
R_SetupFrame ();
|
||||
|
||||
R_SetFrustum ();
|
||||
|
||||
|
@ -1081,13 +1081,11 @@ R_RenderView (void)
|
|||
|
||||
R_PushDlights (vec3_origin);
|
||||
|
||||
R_MarkLeaves (); // done here so we know if we're in
|
||||
// water
|
||||
R_MarkLeaves (); // done here so we know if we're in water
|
||||
|
||||
R_DrawWorld (); // adds static entities to the list
|
||||
R_DrawWorld (); // adds static entities to the list
|
||||
|
||||
S_ExtraUpdate (); // don't let sound get messed up if
|
||||
// going slow
|
||||
S_ExtraUpdate (); // don't let sound get messed up if going slow
|
||||
|
||||
R_DrawEntitiesOnList ();
|
||||
|
||||
|
|
Loading…
Reference in a new issue