mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-01-18 06:51:47 +00:00
chase cam seems to work properly now
This commit is contained in:
parent
49fe4e9f05
commit
6ad55725c2
2 changed files with 21 additions and 12 deletions
|
@ -158,12 +158,20 @@ Cam_DrawViewModel (void)
|
|||
qboolean
|
||||
Cam_DrawPlayer (int playernum)
|
||||
{
|
||||
if (cl.chase == 0 || chase_active->int_val == 0)
|
||||
return false;
|
||||
|
||||
if (cl.spectator && autocam && locked && cl_chasecam->int_val &&
|
||||
spec_track == playernum)
|
||||
return true;
|
||||
if (playernum < 0) {
|
||||
// client player
|
||||
if (cl.chase == 0 || chase_active->int_val == 0)
|
||||
return false;
|
||||
if (!cl.spectator)
|
||||
return true;
|
||||
} else {
|
||||
if (!cl_chasecam->int_val)
|
||||
return true;
|
||||
if (cl.spectator && autocam && locked && spec_track == playernum)
|
||||
return false;
|
||||
if (cl.chase == 0 || chase_active->int_val == 0)
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -797,6 +797,7 @@ CL_LinkPlayers (void)
|
|||
// spawn light flashes, even ones coming from invisible objects
|
||||
if (j == cl.playernum) {
|
||||
VectorCopy (cl.simorg, org);
|
||||
r_player_entity = &cl_player_ents[state - frame->playerstate];
|
||||
} else
|
||||
VectorCopy (state->origin, org);
|
||||
|
||||
|
@ -805,9 +806,12 @@ CL_LinkPlayers (void)
|
|||
// things (due to lack of lights?), so I'm leaving this as is for now.
|
||||
|
||||
// the player object never gets added
|
||||
if (j == cl.playernum && !Cam_DrawPlayer (j)) {
|
||||
r_player_entity = &cl_player_ents[state - frame->playerstate];
|
||||
continue;
|
||||
if (j == cl.playernum) {
|
||||
if (!Cam_DrawPlayer (-1))
|
||||
continue;
|
||||
} else {
|
||||
if (!Cam_DrawPlayer (j))
|
||||
continue;
|
||||
}
|
||||
|
||||
if (!state->modelindex)
|
||||
|
@ -819,9 +823,6 @@ CL_LinkPlayers (void)
|
|||
|| i == 93 || i == 102))
|
||||
continue;
|
||||
|
||||
//if (Cam_DrawPlayer (j))
|
||||
// continue;
|
||||
|
||||
// grab an entity to fill in
|
||||
ent = R_NewEntity ();
|
||||
if (!ent) // object list is full
|
||||
|
|
Loading…
Reference in a new issue