Fixed (I hope) the error sometimes happening when using floating chunk separation

master
Marc Gilleron 2021-10-13 21:03:59 +01:00
parent a2096b2014
commit 1079a80bf8
2 changed files with 5 additions and 0 deletions

View File

@ -29,6 +29,7 @@ Ongoing development - `master`
- `VoxelMesherTransvoxel`: added option to simplify meshes using MeshOptimizer
- `VoxelToolLodTerrain`: added `copy` function
- `VoxelToolLodTerrain`: added `get_voxel_f_interpolated` function, useful to obtain interpolated SDF
- `VoxelToolLodTerrain`: added a function to separate floating chunks as rigid-bodies in a specified region
- `VoxelInstanceGenerator`: added extra option to emit from faces more precisely, especially when meshes got simplified (slower than the other options)
- `VoxelInstancer`: added menu to setup a multimesh item from a scene (similarly to GridMap), which also allows to set up colliders
- `VoxelInstancer`: added initial support for instancing regular scenes (slower than multimeshes)

View File

@ -532,6 +532,10 @@ static Array separate_floating_chunks(VoxelTool &voxel_tool, Box3i world_box, No
// because we build these buffers from connected groups that had negative SDF.
ERR_CONTINUE(mesh.is_null());
if (is_mesh_empty(mesh)) {
continue;
}
// DEBUG
// {
// Ref<VoxelBlockSerializer> serializer;