View Single Post
06-01-09, 03:34 PM   #1045
neolith
A Fallenroot Satyr
 
neolith's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2006
Posts: 22
Originally Posted by duhwhat View Post
How could I get the party frame to auto-hide when converting to a raid?
Put this into your unitframes:
Code:
local partyToggle = CreateFrame('Frame')
partyToggle:RegisterEvent('PLAYER_LOGIN')
partyToggle:RegisterEvent('RAID_ROSTER_UPDATE')
partyToggle:RegisterEvent('PARTY_LEADER_CHANGED')
partyToggle:RegisterEvent('PARTY_MEMBERS_CHANGED')

partyToggle:SetScript('OnEvent', function(self)
	if ((GetNumRaidMembers() > 0)) then
		party:Hide()
	else
		party:Show()
	end
end)
__________________
- The biggest trick the devil ever pulled was convincing the world he didn't exist. -