Okay so at one point I had this chunk of code working but now it no longer works...maybe because i messed with it maybe because i changed the way party frames work. it should show/hide partyframes in raid entering/exiting according to the blizz option set. partyframes of course being attached to GrimPartyMain
any ideas? as you can see its commented out. last piece to fix for some perfect and very sweet party frames. two styles to chose from and movable!
lua Code:
-----------------------------------
-- GUI Party Frame main creation.
-----------------------------------
local GrimPartyMain = CreateFrame("Frame", "GrimPartyMain", UIParent, "SecureHandlerStateTemplate");
--SecureHandler_OnLoad(GrimPartyMain);
--GrimPartyMain:SetFrameRef("GrimPartyMain", GrimPartyMain);
--GrimPartyMain:Execute([[
--GrimPartyMain = self:GetFrameRef("GrimPartyMain");
--]]);
--GrimPartyMain:Execute("raidhideparty = " .. tostring(GetCVar("hidePartyInRaid"))); -- hook to Blizzard option for party raid hide frames
--GrimPartyMain:SetAttribute("_onstate-unitexists", [[
-- --if raidhideparty == 1 and newstate then
-- --GrimPartyMain:Hide()
-- --end
-- --if raidhideparty ~= 1 and newstate then
-- --GrimPartyMain:Show()
-- --end
--]]);
--GrimPartyMain:SetAttribute("unit", "raid1");
--GrimPartyMain(GrimPartyMain, true);
--GrimPartyMain:SetAttribute("state-unitexists", UnitExists("raid1"));
edit --
i should point out i have this function in another file that loads after the function above...
its in the options file and once again partly commented out so i could test if the dummy on the hide/show was the problem but it did not appear to be. although i could see this being a problem one way or the other.
lua Code:
function GrimUI:PartyHideShowFunc()
if GrimUIData.GUIPartyFrame == "show" then
--GrimPartyMain.Show = GrimPartyMain:Show()
GrimPartyMain:Show()
--GrimPartyMain.Hide = GrimUI.Dummy
end
if GrimUIData.GUIPartyFrame == "hide" then
--GrimPartyMain.Hide = GrimPartyMain:Hide()
GrimPartyMain:Hide()
--GrimPartyMain.Show = GrimUI.Dummy
end
end