Notify mesh surface when render_priority changes

This ensures that the mesh properly takes render_priority into account when changed
This commit is contained in:
clayjohn 2023-02-13 18:09:33 -08:00
parent 4a2c2170b4
commit d3b3419aff
2 changed files with 2 additions and 0 deletions

View File

@ -2881,6 +2881,7 @@ void MaterialStorage::material_set_render_priority(RID p_material, int priority)
if (material->data) {
material->data->set_render_priority(priority);
}
material->dependency.changed_notify(Dependency::DEPENDENCY_CHANGED_MATERIAL);
}
bool MaterialStorage::material_is_animated(RID p_material) {

View File

@ -2803,6 +2803,7 @@ void MaterialStorage::material_set_render_priority(RID p_material, int priority)
if (material->data) {
material->data->set_render_priority(priority);
}
material->dependency.changed_notify(Dependency::DEPENDENCY_CHANGED_MATERIAL);
}
bool MaterialStorage::material_is_animated(RID p_material) {