diff --git a/OpenRA.Mods.Common/Widgets/ButtonWidget.cs b/OpenRA.Mods.Common/Widgets/ButtonWidget.cs index 73477db51f..c15242d187 100644 --- a/OpenRA.Mods.Common/Widgets/ButtonWidget.cs +++ b/OpenRA.Mods.Common/Widgets/ButtonWidget.cs @@ -254,6 +254,9 @@ namespace OpenRA.Mods.Common.Widgets public static void DrawBackground(string baseName, Rectangle rect, bool disabled, bool pressed, bool hover, bool highlighted) { + if (string.IsNullOrEmpty(baseName)) + return; + var variant = highlighted ? "-highlighted" : ""; var state = disabled ? "-disabled" : pressed ? "-pressed" :