- fix null pointer crash

This commit is contained in:
Magnus Norddahl 2018-10-30 13:35:15 +01:00
parent f0ec4a6838
commit 453a4cc8b1

View file

@ -334,6 +334,8 @@ bool FLevel::PointInsideSubSector(const float x, const float y, const MapSubsect
kexVec2 pt1, pt2;
surf = leafSurfaces[0][sub - GLSubsectors];
if (!surf)
return false;
// check to see if the point is inside the subsector leaf
for (i = 0; i < surf->numVerts; i++)