- fixed: The check if a line is in range of a bounding box must be exclusive.

Unfortunately I picked the one incorrect version of this check (from A_PainShootSkull) when moving it to an inline function.
This commit is contained in:
Christoph Oelckers 2016-03-29 13:10:15 +02:00
parent 25f5e8449a
commit 84d547adfb

View file

@ -1604,10 +1604,10 @@ inline void AActor::ClearInterpolation()
inline bool FBoundingBox::inRange(const line_t *ld) const
{
return (!(Left() > ld->bbox[BOXRIGHT] ||
Right() < ld->bbox[BOXLEFT] ||
Top() < ld->bbox[BOXBOTTOM] ||
Bottom() > ld->bbox[BOXTOP]));
return Left() < ld->bbox[BOXRIGHT] &&
Right() > ld->bbox[BOXLEFT] &&
Top() > ld->bbox[BOXBOTTOM] &&
Bottom() < ld->bbox[BOXTOP];
}