mirror of
https://github.com/nzp-team/fteqw.git
synced 2024-11-22 12:01:25 +00:00
try to fix bloom. fix some spectating stuff.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4772 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
c636c07165
commit
c8a0c1ad0e
3 changed files with 15 additions and 10 deletions
|
@ -290,7 +290,7 @@ static qboolean InitFlyby(playerview_t *pv, vec3_t selforigin, vec3_t playerorig
|
|||
}
|
||||
|
||||
pv->cam_locked = true;
|
||||
pv->viewentity = pv->cam_spec_track+1;
|
||||
pv->viewentity = pv->playernum+1;//pv->cam_spec_track+1;
|
||||
VectorCopy(vec, pv->cam_desired_position);
|
||||
return true;
|
||||
}
|
||||
|
@ -405,7 +405,7 @@ void Cam_Track(playerview_t *pv, usercmd_t *cmd)
|
|||
if (cl_hightrack.value && !pv->cam_locked)
|
||||
Cam_CheckHighTarget(pv);
|
||||
|
||||
if (!pv->cam_auto || cls.state != ca_active || cl.worldmodel || cl.worldmodel->loadstate != MLS_LOADED)
|
||||
if (!pv->cam_auto || cls.state != ca_active || cl.worldmodel->loadstate != MLS_LOADED)
|
||||
return;
|
||||
|
||||
if (pv->cam_locked && (!cl.players[pv->cam_spec_track].name[0] || cl.players[pv->cam_spec_track].spectator))
|
||||
|
@ -468,6 +468,7 @@ void Cam_Track(playerview_t *pv, usercmd_t *cmd)
|
|||
}
|
||||
self->weaponframe = player->weaponframe;
|
||||
|
||||
VectorCopy(player->viewangles, pv->viewangles);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -911,6 +911,17 @@ void CL_PredictMovePNum (int seat)
|
|||
VectorCopy (pv->viewangles, pv->simangles);
|
||||
}
|
||||
|
||||
if (pv->cam_locked && pv->cam_spec_track >= 0)
|
||||
{
|
||||
extern cvar_t cl_chasecam;
|
||||
if (!cl_chasecam.ival)
|
||||
{
|
||||
VectorCopy(pv->cam_desired_position, pv->simorg);
|
||||
VectorClear(pv->simvel);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (!pv->cam_locked && pv->cam_auto && cl.spectator && pv->cam_spec_track >= 0 && pv->cam_spec_track < cl.allocated_client_slots && pv->viewentity != pv->cam_spec_track+1)
|
||||
{
|
||||
if (cl.inframes[cl.validsequence & UPDATE_MASK].playerstate[pv->cam_spec_track].messagenum == cl.validsequence)
|
||||
|
|
|
@ -115,15 +115,8 @@ static void R_SetupBloomTextures(int w, int h)
|
|||
{
|
||||
sprintf(name, "***bloom*%c*%i***", 'a'+i, j);
|
||||
TEXASSIGN(pingtex[i][j], Image_CreateTexture(name, NULL, IF_CLAMP|IF_NOMIPMAP|IF_NOPICMIP|IF_LINEAR));
|
||||
qglGenTextures(1, &pingtex[i][j]->num);
|
||||
}
|
||||
GL_MTBind(0, GL_TEXTURE_2D, pingtex[i][j]);
|
||||
qglTexImage2D (GL_TEXTURE_2D, 0, GL_RGBA, texwidth[j], texheight[j], 0, GL_RGBA, GL_UNSIGNED_BYTE, NULL);
|
||||
|
||||
qglTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
|
||||
qglTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
|
||||
qglTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
|
||||
qglTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
|
||||
Image_Upload(pingtex[i][j], TF_RGBA32, NULL, NULL, texwidth[j], texheight[j], IF_CLAMP|IF_NOMIPMAP|IF_NOPICMIP|IF_LINEAR);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue