mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-11 07:11:39 +00:00
Fix underwater player clipping issue
git-svn-id: https://svn.eduke32.com/eduke32@7468 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
1ea1f525d9
commit
3926ae2d4f
1 changed files with 15 additions and 0 deletions
|
@ -4498,6 +4498,21 @@ static void P_DoWater(int const playerNum, int const playerBits, int const floor
|
|||
pPlayer->vel.z = 0;
|
||||
}
|
||||
|
||||
int spriteNum;
|
||||
|
||||
for (SPRITES_OF_SECT(pPlayer->cursectnum, spriteNum))
|
||||
if (sprite[spriteNum].statnum == STAT_TRANSPORT)
|
||||
break;
|
||||
|
||||
if (spriteNum == -1)
|
||||
{
|
||||
if (pPlayer->pos.z < ceilZ + PMINHEIGHT)
|
||||
{
|
||||
pPlayer->pos.z = ceilZ + PMINHEIGHT;
|
||||
pPlayer->vel.z = 0;
|
||||
}
|
||||
}
|
||||
|
||||
if (pPlayer->scuba_on && (krand()&255) < 8)
|
||||
{
|
||||
int const spriteNum = A_Spawn(pPlayer->i, WATERBUBBLE);
|
||||
|
|
Loading…
Reference in a new issue