apply patch that fixes prediction of visual effects for Tonik (cvs troubles).

This commit is contained in:
Bill Currie 2000-05-08 21:30:27 +00:00
parent 7932608a22
commit e3d3f3d73c

View file

@ -840,6 +840,7 @@ void CL_LinkPlayers (void)
int msec;
frame_t *frame;
int oldphysent;
vec3_t org;
playertime = realtime - cls.latency + 0.02;
if (playertime > realtime)
@ -855,18 +856,23 @@ void CL_LinkPlayers (void)
// spawn light flashes, even ones coming from invisible objects
if (!gl_flashblend->value || j != cl.playernum) {
if (j == cl.playernum) {
VectorCopy (cl.simorg, org);
} else
VectorCopy (state->origin, org);
if ((state->effects & (EF_BLUE | EF_RED)) == (EF_BLUE | EF_RED)) {
CL_NewDlight (j, state->origin, 200 + (rand()&31), 0.1, 3);
CL_NewDlight (j, org, 200 + (rand()&31), 0.1, 3);
} else if (state->effects & EF_BLUE) {
CL_NewDlight (j, state->origin, 200 + (rand()&31), 0.1, 1);
CL_NewDlight (j, org, 200 + (rand()&31), 0.1, 1);
} else if (state->effects & EF_RED) {
CL_NewDlight (j, state->origin, 200 + (rand()&31), 0.1, 2);
CL_NewDlight (j, org, 200 + (rand()&31), 0.1, 2);
} else if (state->effects & EF_BRIGHTLIGHT) {
state->origin[2] += 16;
CL_NewDlight (j, state->origin, 400 + (rand()&31), 0.1, 0);
state->origin[2] -= 16;
org[2] += 16;
CL_NewDlight (j, org, 400 + (rand()&31), 0.1, 0);
} else if (state->effects & EF_DIMLIGHT) {
CL_NewDlight (j, state->origin, 200 + (rand()&31), 0.1, 0);
CL_NewDlight (j, org, 200 + (rand()&31), 0.1, 0);
}
}