mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-04-27 04:21:47 +00:00
Use pitch/roll for camera tilting
This commit is contained in:
parent
696e405038
commit
f313eece7e
1 changed files with 2 additions and 14 deletions
16
src/p_user.c
16
src/p_user.c
|
|
@ -4306,21 +4306,9 @@ DoABarrelRoll (player_t *player)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (player->mo->standingslope)
|
slope = InvAngle(R_SpriteRotationAngle(player->mo));
|
||||||
{
|
|
||||||
slope = player->mo->standingslope->zangle;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
slope = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (abs((INT32)slope) > ANGLE_11hh)
|
if (AbsAngle(slope) < ANGLE_11hh)
|
||||||
{
|
|
||||||
delta = ( player->mo->angle - player->mo->standingslope->xydirection );
|
|
||||||
slope = -(FixedMul(FINESINE (delta>>ANGLETOFINESHIFT), slope));
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
{
|
||||||
slope = 0;
|
slope = 0;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue