Fix an in-editor scene-saving related crash.

This commit is contained in:
Relintai 2020-04-22 12:35:48 +02:00
parent 9475986ee0
commit a2a9c1f714

View File

@ -505,6 +505,9 @@ void VoxelWorld::set_chunks(const Vector<Variant> &chunks) {
continue; continue;
} }
if (chunk->get_voxel_world() != NULL && chunk->get_voxel_world() != this)
continue;
add_chunk(chunk, chunk->get_position_x(), chunk->get_position_y(), chunk->get_position_z()); add_chunk(chunk, chunk->get_position_x(), chunk->get_position_y(), chunk->get_position_z());
} }
} }