kgPanels Button
Hiya. I'm trying to make a button using kgPanels. I want it to open/close my bags. I also want it to show/hide a different kgPanel when I click it and also when I press the "B" key to open/close my bags.
|
Quote:
OnLoad lua Code:
OnClick lua Code:
In your other panel, add this to the OnLoad script: lua Code:
In both OnLoad scripts, change OtherPanel to some unique name for your panel. |
Rather than setting that global "OtherPanel" in the second panel's OnLoad script, you should just use the method kgPanels provides for accessing other panels:
Code:
function self:OnClick() |
Quote:
|
Or, to make the other panel show/hide when your bags are opened/closed you can do an even *simpler* solution. Set the backpack to your panel's parent.
|
Quote:
|
All times are GMT -6. The time now is 03:57 AM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI