Fix Duke's head bouncing off the ceiling when jumping

git-svn-id: https://svn.eduke32.com/eduke32@7439 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2019-03-19 21:29:18 +00:00 committed by Christoph Oelckers
parent e77332db32
commit 1a9944a260

View file

@ -5127,12 +5127,12 @@ void P_ProcessInput(int playerNum)
}
}
if ((sectorLotag != ST_2_UNDERWATER || ceilZ != pPlayer->truecz) && pPlayer->pos.z < (ceilZ + PCROUCHINCREMENT))
if ((sectorLotag != ST_2_UNDERWATER || ceilZ != pPlayer->truecz) && pPlayer->opos.z < (ceilZ + PMINHEIGHT))
{
pPlayer->jumping_counter = 0;
if (pPlayer->vel.z < 0)
pPlayer->vel.x = pPlayer->vel.y = 0;
pPlayer->vel.z = 256;
pPlayer->vel.z = 128;
}
}