2
0
mirror of https://github.com/Laupetin/OpenAssetTools.git synced 2025-11-27 15:02:06 +00:00

chore: use std min and std max in bsp utils

This commit is contained in:
Jan Laupetin
2025-11-06 20:25:32 +01:00
parent bbb07e2b59
commit a8456f88a4
2 changed files with 14 additions and 32 deletions

View File

@@ -217,8 +217,7 @@ namespace BSP
size_t leafObjectCount = tree->leaf->getObjectCount();
assert(leafObjectCount > 0);
if (leafObjectCount > highestLeafObjectCount)
highestLeafObjectCount = leafObjectCount;
highestLeafObjectCount = std::max(leafObjectCount, highestLeafObjectCount);
// BO2 has a maximum limit of 128 children per AABB tree (essentially),
// so this is fixed by adding multiple parent AABB trees that hold 128 children each