- fixed: armor factor application was done wrong.

- fixed: APROP_Invulnerable could only be set and unset but not checked.
- fixed: Two sided polyobjects applied thrust to sctors in a way that did not work.


SVN r2620 (trunk)
This commit is contained in:
Christoph Oelckers 2010-08-28 12:57:23 +00:00
commit 5647fed0cf
3 changed files with 25 additions and 8 deletions

View file

@ -1245,6 +1245,7 @@ bool FPolyObj::CheckMobjBlocking (side_t *sd)
bool blocked;
ld = sd->linedef;
top = (ld->bbox[BOXTOP]-bmaporgy) >> MAPBLOCKSHIFT;
bottom = (ld->bbox[BOXBOTTOM]-bmaporgy) >> MAPBLOCKSHIFT;
left = (ld->bbox[BOXLEFT]-bmaporgx) >> MAPBLOCKSHIFT;
@ -1294,6 +1295,17 @@ bool FPolyObj::CheckMobjBlocking (side_t *sd)
{
continue;
}
// We have a two-sided linedef so we should only check one side
// so that the thrust from both sides doesn't cancel each other out.
// Best use the one facing the player and ignore the back side.
if (ld->sidedef[1] != NULL)
{
int side = P_PointOnLineSide(mobj->x, mobj->y, ld);
if (ld->sidedef[side] != sd)
{
continue;
}
}
ThrustMobj (mobj, sd);
blocked = true;
}