But.. I got an alternative version to work (I think..)
One Panel (4) attached to PitBullUnitFrame1 (220x110) (hides IC)
One Panel (5) to QuartzCastBar (220x30) (hides IC)
One Panel (6) set to show in combat (220x140) (Shows IC)
-- Show / Hide panel IN of Combat function eePanels2:PLAYER_REGEN_DISABLED() eePanel4:Hide() eePanel5:Hide() eepanel6:Show() end -- Show / Hide panel OUT of Combat function eePanels2:PLAYER_REGEN_ENABLED() eePanel4:Show() eePanel5:Show() eepanel6:Hide() end -- Ace2 event listeners; can't do this in more than one script eePanels2:RegisterEvent("PLAYER_REGEN_DISABLED") eePanels2:RegisterEvent("PLAYER_REGEN_ENABLED")
The only remaining problem is that on initial log in eepanel6 is not hidden. It only hides and shows correctly after the first time I enter combat. Is there a way of making panel6 hidden as it should be when I log in? the parent of panel6 is currently UIParent.
I set Panel6 to be totally transparent initially so it can't be seen on the UI at all and then when I actually am entered into combat the script changes the viability of Panel so it can be seen. I used ' eePanel6:SetBackdropBorderColor(255,0,0,230)' which puts a red border round the frame, however I don't really want a border on it.. is there a command for setting the gradient colours on the panel? (actually, is there a command to load a texture file onto the panel via the script?)