mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-29 20:50:58 +00:00
Update p_user.c
This commit is contained in:
parent
a22af36305
commit
f6e8226c4e
1 changed files with 16 additions and 34 deletions
22
src/p_user.c
22
src/p_user.c
|
@ -6993,8 +6993,6 @@ static void P_NiGHTSMovement(player_t *player)
|
|||
UINT16 visangle;
|
||||
#ifdef ROTSPRITE
|
||||
angle_t rollangle = 0;
|
||||
UINT8 turningstate = 0;
|
||||
UINT8 turndiff = 24;
|
||||
#endif
|
||||
|
||||
player->pflags &= ~PF_DRILLING;
|
||||
|
@ -7503,15 +7501,6 @@ static void P_NiGHTSMovement(player_t *player)
|
|||
flystate = S_PLAY_NIGHTS_FLY0;
|
||||
if (player->pflags & PF_DRILLING)
|
||||
flystate++; // shift to S_PLAY_NIGHTS_DRILL0-C
|
||||
else
|
||||
{
|
||||
if ((visangle >= (90-turndiff) && visangle <= (90+turndiff))
|
||||
|| (visangle >= (270-turndiff) && visangle <= (270+turndiff)))
|
||||
{
|
||||
turningstate = 3;
|
||||
flystate = S_PLAY_NIGHTS_DRILL0;
|
||||
}
|
||||
}
|
||||
|
||||
if (player->flyangle >= 90 && player->flyangle <= 270)
|
||||
{
|
||||
|
@ -7524,7 +7513,7 @@ static void P_NiGHTSMovement(player_t *player)
|
|||
}
|
||||
|
||||
rollangle = FixedAngle(visangle*FRACUNIT);
|
||||
#endif // ROTSPRITE
|
||||
#endif
|
||||
}
|
||||
|
||||
if (player->mo->state != &states[flystate])
|
||||
|
@ -7532,14 +7521,7 @@ static void P_NiGHTSMovement(player_t *player)
|
|||
|
||||
#ifdef ROTSPRITE
|
||||
player->mo->rollangle = rollangle;
|
||||
if (turningstate)
|
||||
{
|
||||
player->mo->frame = turningstate;
|
||||
player->mo->tics = -1;
|
||||
}
|
||||
else if (player->mo->tics == -1)
|
||||
player->mo->tics = states[flystate].tics;
|
||||
#endif // ROTSPRITE
|
||||
#endif
|
||||
|
||||
if (player == &players[consoleplayer])
|
||||
localangle = player->mo->angle;
|
||||
|
|
Loading…
Reference in a new issue