mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-11 18:50:46 +00:00
When found a camera sprite for viewscreen, set position etc. immediately.
Instead of later in P_ProcessInput(). This fixes one drawrooms() call in between where the sectnum is the camera's, but the position the player's, which can lead to a slow "outer view" render in Polymer. git-svn-id: https://svn.eduke32.com/eduke32@3142 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
861eea9b16
commit
e7e777348b
2 changed files with 11 additions and 13 deletions
|
@ -4577,15 +4577,6 @@ void P_ProcessInput(int32_t snum)
|
|||
|
||||
if (p->newowner >= 0)
|
||||
{
|
||||
i = p->newowner;
|
||||
p->pos.x = SX;
|
||||
p->pos.y = SY;
|
||||
p->pos.z = SZ;
|
||||
p->ang = SA;
|
||||
p->vel.x = p->vel.y = s->xvel = 0;
|
||||
p->look_ang = 0;
|
||||
p->rotscrnang = 0;
|
||||
|
||||
P_DoCounters(p);
|
||||
|
||||
if (*aplWeaponWorksLike[p->curr_weapon] == HANDREMOTE_WEAPON)
|
||||
|
|
|
@ -3258,9 +3258,8 @@ void P_CheckSectors(int32_t snum)
|
|||
case VIEWSCREEN__STATIC:
|
||||
case VIEWSCREEN2__STATIC:
|
||||
{
|
||||
i = headspritestat[STAT_ACTOR];
|
||||
|
||||
while (i >= 0)
|
||||
// Try to find a camera sprite for the viewscreen.
|
||||
for (SPRITES_OF(STAT_ACTOR, i))
|
||||
{
|
||||
if (PN == CAMERA1 && SP == 0 && sprite[neartagsprite].hitag == SLT)
|
||||
{
|
||||
|
@ -3278,9 +3277,17 @@ void P_CheckSectors(int32_t snum)
|
|||
|
||||
// parallaxtype = 2;
|
||||
p->newowner = i;
|
||||
|
||||
p->pos.x = SX;
|
||||
p->pos.y = SY;
|
||||
p->pos.z = SZ;
|
||||
p->ang = SA;
|
||||
p->vel.x = p->vel.y = sprite[p->i].xvel = 0;
|
||||
p->look_ang = 0;
|
||||
p->rotscrnang = 0;
|
||||
|
||||
return;
|
||||
}
|
||||
i = nextspritestat[i];
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue