mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-12 11:10:39 +00:00
Fix for E1L1 dumpster fire issue
git-svn-id: https://svn.eduke32.com/eduke32@8636 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
5a13be1f7b
commit
46b62aa6aa
1 changed files with 12 additions and 2 deletions
|
@ -416,6 +416,7 @@ void A_GetZLimits(int const spriteNum)
|
|||
auto const pSprite = &sprite[spriteNum];
|
||||
int32_t ceilhit, florhit;
|
||||
int const clipDist = A_GetClipdist(spriteNum, -1);
|
||||
auto const oceilz = actor[spriteNum].ceilingz;
|
||||
|
||||
VM_GetZRange(spriteNum, &ceilhit, &florhit, pSprite->statnum == STAT_PROJECTILE ? clipDist << 3 : clipDist);
|
||||
actor[spriteNum].flags &= ~SFLAG_NOFLOORSHADOW;
|
||||
|
@ -440,6 +441,15 @@ void A_GetZLimits(int const spriteNum)
|
|||
actor[spriteNum].floorz = sector[pSprite->sectnum].floorz;
|
||||
}
|
||||
}
|
||||
|
||||
// in E1L1, the dumpster fire sprites break after calling this function because the cardboard boxes
|
||||
// are a few units higher than the fire and are detected as the "ceiling"
|
||||
// unfortunately, this trips the "ifgapzl 16 break" in "state firestate"
|
||||
if ((ceilhit&49152) == 49152 && (sprite[ceilhit&(MAXSPRITES-1)].cstat&48) == 0)
|
||||
{
|
||||
if (pSprite->z >= actor[spriteNum].floorz)
|
||||
actor[spriteNum].ceilingz = oceilz;
|
||||
}
|
||||
}
|
||||
|
||||
void A_Fall(int const spriteNum)
|
||||
|
|
Loading…
Reference in a new issue