Fix wrong condition for unloading mesh blocks

This commit is contained in:
Marc Gilleron 2021-12-16 22:17:20 +00:00
parent ed5bca22c7
commit f67077b698

View File

@ -497,7 +497,7 @@ void VoxelTerrain::unview_mesh_block(Vector3i bpos, bool mesh_flag, bool collisi
}
}
if (block->collision_viewers.get() == 0 && block->collision_viewers.get() == 0) {
if (block->mesh_viewers.get() == 0 && block->collision_viewers.get() == 0) {
unload_mesh_block(bpos);
}
}