clipmove() patch from Nuke.YKT:

"In some edge cases posx/y might be 'inside' of neighbor sector. I've added double check for this case"

git-svn-id: https://svn.eduke32.com/eduke32@7827 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2019-07-24 01:37:54 +00:00 committed by Christoph Oelckers
parent df28860bad
commit 417318c271

View file

@ -1149,8 +1149,17 @@ int32_t clipmove(vec3_t * const pos, int16_t * const sectnum, int32_t xvect, int
}
// We're not interested in any sector reached by portal traversal that we're "inside" of.
if (!curspr && dasect != initialsectnum && inside(pos->x, pos->y, dasect) == 1) break;
else if (clipyou)
if (!curspr && dasect != initialsectnum && inside(pos->x, pos->y, dasect) == 1)
{
int k;
for (k=startwall; k<endwall; k++)
if (wall[k].nextsector == initialsectnum)
break;
if (k == endwall)
break;
}
if (clipyou)
{
int16_t const objtype = curspr ? (int16_t)(curspr - (uspritetype *)sprite) + 49152 : j + 32768;