- fixed: a sight check that starts right on a linedef should ignore that linedef.

Trying to calculate a slope to the target from this linedef's opening will always result in failure because it'd involve a division by zero.
This commit is contained in:
Christoph Oelckers 2016-04-07 01:16:07 +02:00
parent b774fed93e
commit 3923039a1b
1 changed files with 3 additions and 0 deletions

View File

@ -216,6 +216,9 @@ bool SightCheck::PTR_SightTraverse (intercept_t *in)
if (open.range == 0 && open.portalflags == 0 && (lport == NULL || lport->mType != PORTT_LINKED)) // quick test for totally closed doors (must be delayed if portal checks are needed, though) if (open.range == 0 && open.portalflags == 0 && (lport == NULL || lport->mType != PORTT_LINKED)) // quick test for totally closed doors (must be delayed if portal checks are needed, though)
return false; // stop return false; // stop
if (in->frac == 0)
return true;
// check bottom // check bottom
if (open.bottom > LINEOPEN_MIN) if (open.bottom > LINEOPEN_MIN)
{ {