From 44b20f21326491d093148381bf39286c7d791b5d Mon Sep 17 00:00:00 2001 From: Salikh Gurgenidze Date: Tue, 18 Nov 2025 21:43:39 +0400 Subject: [PATCH] fix: bag main functionality --- UI/BagFrame.lua | 9 ++++----- UI/BagFrame.xml | 37 +++++++++++++++++++++++++++++++++++-- 2 files changed, 39 insertions(+), 7 deletions(-) diff --git a/UI/BagFrame.lua b/UI/BagFrame.lua index eff20bd..dc1a593 100644 --- a/UI/BagFrame.lua +++ b/UI/BagFrame.lua @@ -1608,11 +1608,10 @@ function Guda_BagFrame_HighlightBagButton(bagID) if bagID == -2 then -- Keyring button buttonName = "Guda_BagFrame_Toolbar_KeyringButton" - elseif bagID >= 1 and bagID <= 4 then - -- Bag buttons 1-4 + elseif bagID >= 0 and bagID <= 4 then + -- Bag buttons 0-4 (0 is backpack) buttonName = "Guda_BagFrame_Toolbar_BagSlot" .. bagID else - -- Bag 0 (backpack) has no button in the toolbar return end @@ -1625,8 +1624,8 @@ end -- Clear bag button highlighting function Guda_BagFrame_ClearBagButtonHighlight() - -- Clear highlight from all bag buttons (1-4) - for bagID = 1, 4 do + -- Clear highlight from all bag buttons (0-4) + for bagID = 0, 4 do local buttonName = "Guda_BagFrame_Toolbar_BagSlot" .. bagID local button = getglobal(buttonName) if button then diff --git a/UI/BagFrame.xml b/UI/BagFrame.xml index 3462f98..d41c60d 100644 --- a/UI/BagFrame.xml +++ b/UI/BagFrame.xml @@ -273,8 +273,8 @@ - - + + +