add null check in MeshInstance::_mesh_changed()

This commit is contained in:
Angad Kambli 2021-02-18 16:36:27 +05:30
parent 96a3f01ac5
commit 013fc360d7
1 changed files with 1 additions and 0 deletions

View File

@ -701,6 +701,7 @@ bool MeshInstance::is_software_skinning_transform_normals_enabled() const {
}
void MeshInstance::_mesh_changed() {
ERR_FAIL_COND(mesh.is_null());
materials.resize(mesh->get_surface_count());
if (software_skinning) {