qbsp: if Q2_CONTENTS_SOLID bit is set, always assign invalid area

This commit is contained in:
Eric Wasylishen 2023-03-26 19:02:25 -06:00
parent 759811b548
commit f12cefb2c9
1 changed files with 7 additions and 5 deletions

View File

@ -193,12 +193,14 @@ static void ExportLeaf(node_t *node)
}
dleaf.nummarksurfaces = static_cast<int>(map.bsp.dleaffaces.size()) - dleaf.firstmarksurface;
if (map.leakfile) {
if (!(dleaf.contents & Q2_CONTENTS_SOLID)) {
dleaf.area = 1;
}
if (dleaf.contents & Q2_CONTENTS_SOLID) {
dleaf.area = AREA_INVALID;
} else {
dleaf.area = node->area;
if (map.leakfile) {
dleaf.area = 1;
} else {
dleaf.area = node->area;
}
}
dleaf.cluster = node->viscluster;