X-Git-Url: http://git.xonotic.org/?a=blobdiff_plain;f=portals.c;h=2872a8ca89c1a3faaa1fe22ef11cc8be242a1a94;hb=a3482c67248044c9c3dfe6ef96781d2e814fdeeb;hp=3b770f9ea40c79cbf4b55bf8d77bcee9e16e0d5e;hpb=1a8f8b37c07a75324cc298e2188356618dfb7635;p=xonotic%2Fdarkplaces.git diff --git a/portals.c b/portals.c index 3b770f9e..2872a8ca 100644 --- a/portals.c +++ b/portals.c @@ -1,6 +1,7 @@ #include "quakedef.h" #include "polygon.h" +#include "portals.h" #define MAXRECURSIVEPORTALPLANES 1024 #define MAXRECURSIVEPORTALS 256 @@ -338,7 +339,7 @@ static void Portal_RecursiveFlow (portalrecursioninfo_t *info, mleaf_t *leaf, in VectorCopy(vertex3f + elements[1] * 3, v + 3); VectorCopy(vertex3f + elements[2] * 3, v + 6); if (PointInfrontOfTriangle(info->eye, v + 0, v + 3, v + 6) - && (insidebox || TriangleOverlapsBox(v, v + 3, v + 6, info->boxmins, info->boxmaxs)) + && (insidebox || TriangleBBoxOverlapsBox(v, v + 3, v + 6, info->boxmins, info->boxmaxs)) && (!info->exact || Portal_PortalThroughPortalPlanes(&portalplanes[firstclipplane], numclipplanes, v, 3, &portaltemppoints2[0][0], 256) > 0)) { addedtris = true;