Fix instances of things still using (options >> ZSHIFT)

This commit is contained in:
Sally Coolatta 2020-09-27 04:22:09 -04:00
parent 72672d68cf
commit 857f295836
3 changed files with 9 additions and 17 deletions

View file

@ -594,18 +594,14 @@ void K_SpawnBattleCapsules(void)
z = P_GetZAt(sec->c_slope, x, y, sec->ceilingheight) - mobjinfo[MT_BATTLECAPSULE].height;
floorheights[0] = z;
if (mt->options >> ZSHIFT)
z -= ((mt->options >> ZSHIFT) << FRACBITS);
z -= (mt->z << FRACBITS);
}
else
{
z = P_GetZAt(sec->f_slope, x, y, sec->floorheight);
floorheights[0] = z;
if (mt->options >> ZSHIFT)
z += ((mt->options >> ZSHIFT) << FRACBITS);
z += (mt->z << FRACBITS);
}

View file

@ -186,7 +186,7 @@ void K_DoIngameRespawn(player_t *player)
else
{
sector_t *s;
fixed_t z = (beststart->options >> ZSHIFT) * FRACUNIT;
fixed_t z = beststart->z * FRACUNIT;
player->respawn.pointx = beststart->x << FRACBITS;
player->respawn.pointy = beststart->y << FRACBITS;

View file

@ -118,17 +118,13 @@ anchor_height
const mapthing_t * a,
const sector_t * s
){
if (a->options & MTF_OBJECTFLIP)
{
INT16 z = ( a->options >> ZSHIFT );
if (a->options & MTF_OBJECTFLIP)
{
return ( s->ceilingheight >> FRACBITS ) - z;
}
else
{
return ( s->floorheight >> FRACBITS ) + z;
}
return ( s->ceilingheight >> FRACBITS ) - a->z;
}
else
{
return ( s->floorheight >> FRACBITS ) + a->z;
}
}