mirror of
https://github.com/ZDoom/Raze.git
synced 2025-05-31 17:31:00 +00:00
- Use turnscale
in controller pitch calculations, which is only used in SW when on a sector object, and is original behaviour.
This commit is contained in:
parent
00e12ea031
commit
a423b93ad8
1 changed files with 3 additions and 3 deletions
|
@ -189,11 +189,11 @@ void processMovement(InputPacket* const currInput, InputPacket* const inputBuffe
|
||||||
bool const strafing = buttonMap.ButtonDown(gamefunc_Strafe) && allowstrafe;
|
bool const strafing = buttonMap.ButtonDown(gamefunc_Strafe) && allowstrafe;
|
||||||
float const mousevelscale = keymove * (1.f / 160.f);
|
float const mousevelscale = keymove * (1.f / 160.f);
|
||||||
double const hidprescale = g_gameType & GAMEFLAG_PSEXHUMED ? 5. : 1.;
|
double const hidprescale = g_gameType & GAMEFLAG_PSEXHUMED ? 5. : 1.;
|
||||||
double const hidspeed = getTicrateScale(running ? RUNNINGTURNBASE : NORMALTURNBASE) * BAngToDegree;
|
double const hidspeed = getTicrateScale(running ? RUNNINGTURNBASE : NORMALTURNBASE) * turnscale * BAngToDegree;
|
||||||
|
|
||||||
// process mouse and initial controller input.
|
// process mouse and initial controller input.
|
||||||
if (!strafing)
|
if (!strafing)
|
||||||
currInput->avel += float(hidInput->mouseturnx + (scaleAdjust * hidInput->dyaw * hidspeed * turnscale));
|
currInput->avel += float(hidInput->mouseturnx + (scaleAdjust * hidInput->dyaw * hidspeed));
|
||||||
else
|
else
|
||||||
currInput->svel -= int16_t(((hidInput->mousemovex * mousevelscale) + (scaleAdjust * hidInput->dyaw * keymove)) * hidprescale);
|
currInput->svel -= int16_t(((hidInput->mousemovex * mousevelscale) + (scaleAdjust * hidInput->dyaw * keymove)) * hidprescale);
|
||||||
|
|
||||||
|
@ -216,7 +216,7 @@ void processMovement(InputPacket* const currInput, InputPacket* const inputBuffe
|
||||||
if (turnleft || turnright)
|
if (turnleft || turnright)
|
||||||
{
|
{
|
||||||
updateTurnHeldAmt(scaleAdjust);
|
updateTurnHeldAmt(scaleAdjust);
|
||||||
float const turnamount = float(scaleAdjust * hidspeed * turnscale * (isTurboTurnTime() ? 1. : PREAMBLESCALE));
|
float const turnamount = float(scaleAdjust * hidspeed * (isTurboTurnTime() ? 1. : PREAMBLESCALE));
|
||||||
|
|
||||||
if (turnleft)
|
if (turnleft)
|
||||||
currInput->avel -= turnamount;
|
currInput->avel -= turnamount;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue