mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-10 23:02:03 +00:00
- Blood: Factor in game's tic-rate when aiming/looking up/down.
* Doesn't matter for Blood, but will matter for SW in a unified approach. Might as well get it right here. * Appreciate the literal doubles in lieu of the enums isn't great, but this function will go into the backend in due course.
This commit is contained in:
parent
d2501007f2
commit
f7957fc237
1 changed files with 4 additions and 5 deletions
|
@ -1306,7 +1306,6 @@ int ActionScan(PLAYER *pPlayer, int *a2, int *a3)
|
|||
|
||||
enum
|
||||
{
|
||||
HORIZ_SPEED = 14,
|
||||
PLAYER_HORIZ_MIN = -79,
|
||||
PLAYER_HORIZ_MAX = 219
|
||||
};
|
||||
|
@ -1378,11 +1377,11 @@ void sethorizon(PLAYER *pPlayer, fixed_t const q16horz, double const scaleAdjust
|
|||
|
||||
// adjust q16horiz negative
|
||||
if (pInput->actions & SB_AIM_DOWN)
|
||||
horizAngle -= scaleAdjust * (HORIZ_SPEED >> 1);
|
||||
horizAngle -= scaleAdjust * (210. / GameTicRate);
|
||||
|
||||
// adjust q16horiz positive
|
||||
if (pInput->actions & SB_AIM_UP)
|
||||
horizAngle += scaleAdjust * (HORIZ_SPEED >> 1);
|
||||
horizAngle += scaleAdjust * (210. / GameTicRate);
|
||||
}
|
||||
|
||||
// this is the unlocked type
|
||||
|
@ -1392,11 +1391,11 @@ void sethorizon(PLAYER *pPlayer, fixed_t const q16horz, double const scaleAdjust
|
|||
|
||||
// adjust q16horiz negative
|
||||
if (pInput->actions & SB_LOOK_DOWN)
|
||||
horizAngle -= scaleAdjust * HORIZ_SPEED;
|
||||
horizAngle -= scaleAdjust * (420. / GameTicRate);
|
||||
|
||||
// adjust q16horiz positive
|
||||
if (pInput->actions & SB_LOOK_UP)
|
||||
horizAngle += scaleAdjust * HORIZ_SPEED;
|
||||
horizAngle += scaleAdjust * (420. / GameTicRate);
|
||||
}
|
||||
|
||||
if (pInput->actions & SB_CENTERVIEW)
|
||||
|
|
Loading…
Reference in a new issue