Ahh so thats how you use the fetch bit. ill have to do that then and see how it goes.
As for registering the event in both panels i recall it being mentioned on the sample scripts page though i may have misread it. I just went to look abnd the page is throwing an error at the moment so ill edit later once i can access the page.
As far as putting the scripts in the panel with the higher number when ever i use the script to find a frame and get the numbers then do a /reloadui the numbers kept changing. Example being the 10 man panel listed as panel 1 initially then after reload it was panel 3. To be fair i havent updated kgpanels in forever since ive never had an issue so ill try that first.
Thanks again for the assist. Learning little by little hehe.
EDIT: Finally got the page of the sample scripts to load, this is a direct quote:
Adjusting Panels based on Raid or 5 Main party
In each Panel set the OnLoad script
self:RegisterEvent("PLAYER_ENTERING_WORLD")
self:RegisterEvent("PARTY_MEMBERS_CHANGED")
self:RegisterEvent("RAID_ROSTER_UPDATE")
Then in each Panel OnEvent script:
local pmems = GetNumPartyMembers()
local rmems = GetNumRaidMembers()
if (pmems < 1 and rmems < 1) or (pmems > 0 and pmems < 6 and rmems < 6) then
self:Hide()
else
self:Show()
end
|
Obviously there are slight differences in the actual script but the general idea is the same. you'll also note it does mention putting it in each panel. though i agree if i can do it in one panel (perhaps one that isnt going to be hidden at all if possible) makes it easier to fix later.