From 372e5498311d81127de4e53d7b84517d6ec5e372 Mon Sep 17 00:00:00 2001 From: M4rchyS Date: Thu, 11 Dec 2025 19:11:40 +0100 Subject: [PATCH] Add null verification to avoid background theme error in texture shader properties --- editor/inspector/editor_inspector.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/editor/inspector/editor_inspector.cpp b/editor/inspector/editor_inspector.cpp index a268ac8d9d..434c850c60 100644 --- a/editor/inspector/editor_inspector.cpp +++ b/editor/inspector/editor_inspector.cpp @@ -468,7 +468,7 @@ void EditorProperty::_notification(int p_what) { // Only draw the label if it's not empty. if (label.is_empty()) { size.height = 0; - } else if (sub_inspector_color_level >= 0) { + } else if (sub_inspector_color_level >= 0 && theme_cache.sub_inspector_background[sub_inspector_color_level].is_valid()) { draw_style_box(theme_cache.sub_inspector_background[sub_inspector_color_level], Rect2(Vector2(), size)); } else { draw_style_box(selected ? theme_cache.background_selected : theme_cache.background, Rect2(Vector2(), size));