Merge pull request #95503 from clayjohn/instance_none_crash

Avoid indexing instances without a base in scene cull phase
This commit is contained in:
Rémi Verschelde 2024-09-03 11:43:08 +02:00
commit 032235b6fc
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -1783,6 +1783,8 @@ void RendererSceneCull::_update_instance(Instance *p_instance) {
if (p_instance->scenario) {
RendererSceneOcclusionCull::get_singleton()->scenario_set_instance(p_instance->scenario->self, p_instance->self, p_instance->base, *instance_xform, p_instance->visible);
}
} else if (p_instance->base_type == RS::INSTANCE_NONE) {
return;
}
if (!p_instance->aabb.has_surface()) {