mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-15 00:42:08 +00:00
- Blood: fixed incorrect underwater movement speed
The 'posture == 1' case has gotten lost while consolidating the redundant code.
This commit is contained in:
parent
ac4be79e96
commit
f7a2fd29ba
1 changed files with 1 additions and 1 deletions
|
@ -1587,7 +1587,7 @@ void ProcessInput(PLAYER* pPlayer)
|
|||
|
||||
if ((pInput->fvel || pInput->svel) && (pPlayer->posture == 1 || actor->xspr.height < 256))
|
||||
{
|
||||
const double speed = 1. - (actor->xspr.height < 256 ? actor->xspr.height * (1. / 256.) : 0);
|
||||
const double speed = pPlayer->posture == 1? 1. : 1. - (actor->xspr.height < 256 ? actor->xspr.height * (1. / 256.) : 0);
|
||||
const double& fvAccel = pInput->fvel > 0 ? pPosture->frontAccel : pPosture->backAccel;
|
||||
const double& svAccel = pPosture->sideAccel;
|
||||
actor->vel.XY() += DVector2(pInput->fvel * fvAccel, pInput->svel * svAccel).Rotated(actor->spr.angle) * speed;
|
||||
|
|
Loading…
Reference in a new issue