optimize collisions calculations (remove the stupid)

This commit is contained in:
MihailRis 2026-02-18 18:54:49 +03:00
parent 49aa7cdfba
commit b0d231c927
9 changed files with 134 additions and 103 deletions

View file

@ -173,7 +173,7 @@ void WorldGenerator::placeStructure(
}
auto& otherPrototype = *found->second;
auto chunkAABB = gen_chunk_aabb(chunkX + lcx, chunkZ + lcz);
if (chunkAABB.intersect(aabb)) {
if (chunkAABB.intersects(aabb)) {
otherPrototype.placements.emplace_back(
priority,
StructurePlacement {