mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-04-04 00:41:02 +00:00
split r_isviewpointfirstperson
This commit is contained in:
parent
11e6cf0ade
commit
e157391387
2 changed files with 11 additions and 1 deletions
10
src/r_main.c
10
src/r_main.c
|
@ -1011,9 +1011,10 @@ void R_SkyboxFrame(player_t *player)
|
|||
R_SetupFreelook();
|
||||
}
|
||||
|
||||
boolean R_IsViewpointFirstPerson(player_t *player, boolean skybox)
|
||||
boolean R_ViewpointHasChasecam(player_t *player)
|
||||
{
|
||||
boolean chasecam = false;
|
||||
|
||||
if (splitscreen && player == &players[secondarydisplayplayer] && player != &players[consoleplayer])
|
||||
chasecam = (cv_chasecam2.value != 0);
|
||||
else
|
||||
|
@ -1024,6 +1025,13 @@ boolean R_IsViewpointFirstPerson(player_t *player, boolean skybox)
|
|||
else if (player->spectator) // no spectator chasecam
|
||||
chasecam = false; // force chasecam off
|
||||
|
||||
return chasecam;
|
||||
}
|
||||
|
||||
boolean R_IsViewpointFirstPerson(player_t *player, boolean skybox)
|
||||
{
|
||||
boolean chasecam = R_ViewpointHasChasecam(player);
|
||||
|
||||
// cut-away view stuff
|
||||
if (player->awayviewtics || skybox)
|
||||
return chasecam;
|
||||
|
|
|
@ -104,6 +104,8 @@ void R_ExecuteSetViewSize(void);
|
|||
|
||||
void R_SetupFrame(player_t *player);
|
||||
void R_SkyboxFrame(player_t *player);
|
||||
|
||||
boolean R_ViewpointHasChasecam(player_t *player);
|
||||
boolean R_IsViewpointFirstPerson(player_t *player, boolean skybox);
|
||||
|
||||
// Called by D_Display.
|
||||
|
|
Loading…
Reference in a new issue