I'd like to share the code I use to force a 25/10man raid layout when inside a 25/10man raid instance, the purpose for this code is for those of you who use layouts for 40man that are scaled down and when you raid your guild has more than 25 people in the raid waiting to be subbed in or whatnot. This will force it to only show the raid 25 layout (set the raid 25layout to only shows groups 1-5 and it will hide the other groups)
Step 1:
Add two new events go to the pitbull menu, go to modules, go to lua texts, in the new event box your going to add in three differant ones, both of update for checklist should be set to "player"
Now go create a new lua text for your player layout Below the text box use the event dropdown menu and select, PLAYER_ENTERING_WORLD, RAID_ROSTER_UPDATE, and ZONE_CHANGED_NEW_AREA.
This is the code I used for this:
local zone = GetRealZoneText()
local inInstance, instanceType = IsInInstance()
if inInstance and instanceType == "raid" then
if zone == "Icecrown Citadel" or zone == "Trial of the Crusader" or zone == "Ulduar" or zone == "Vault of Archavon" or zone == "The Eye of Eternity" or zone == "The Obsidian Sanctum" or zone == "Onyxia's Lair" or zone == "Naxxramas" or zone == "Sunwell Plateau" or zone == "Black Temple" or zone == "Hyjal Summit" or zone == "The Eye" or zone == "Serpentshrine Cavern" or zone == "Magtheridon's Lair" or zone == "Gruul's Lair" or zone == "Zul'Aman" or zone == "Karazhan" or zone == "Zul'Gurub" or zone == "Ruins of Ahn'Qiraj" then
PitBull4.StateHeader:SetAttribute("forced_state","raid25")
else
PitBull4.StateHeader:SetAttribute("forced_state",nil)
end
else
PitBull4.StateHeader:SetAttribute("forced_state",nil)
end
When you enter any of those raids now it will force pitbull to use a layout that is shown in Raid25 only, anything else won't be shown.
Note: this should work with just PLAYER_ENTERING_WORLD because that fires everytime you enter an instance but for some reason it isn't.
Ey dont mean to spam or anything i posted this a page back and im still looking for help on how to do it, blizzard recently added an event where you have a threatstatus and i want to make it so omen shows and toggles recount if I have a certain threat status on my target.
"status
Integer - returns the threat status for the unit on the mob, or nil if unit is not on mob's threat table. (3 = securely tanking, 2 = insecurely tanking, 1 = not tanking but higher threat than tank, 0 = not tanking and lower threat than tank)
threatpct "
0
http://www.wowace.com/addons/pitbull4/tickets/706-hide-boss-frames/
0
credit goes to pitbull authors all i did was add in option for boss frames
0
Step 1:
Add two new events go to the pitbull menu, go to modules, go to lua texts, in the new event box your going to add in three differant ones, both of update for checklist should be set to "player"
Type in exactly this:
PLAYER_ENTERING_WORLD
RAID_ROSTER_UPDATE
ZONE_CHANGED_NEW_AREA
Now go create a new lua text for your player layout Below the text box use the event dropdown menu and select, PLAYER_ENTERING_WORLD, RAID_ROSTER_UPDATE, and ZONE_CHANGED_NEW_AREA.
This is the code I used for this:
When you enter any of those raids now it will force pitbull to use a layout that is shown in Raid25 only, anything else won't be shown.
Note: this should work with just PLAYER_ENTERING_WORLD because that fires everytime you enter an instance but for some reason it isn't.
0
http://www.wowwiki.com/API_UnitDetailedThreatSituation is the linky.
"status
Integer - returns the threat status for the unit on the mob, or nil if unit is not on mob's threat table. (3 = securely tanking, 2 = insecurely tanking, 1 = not tanking but higher threat than tank, 0 = not tanking and lower threat than tank)
threatpct "
0
http://www.wowwiki.com/API_UnitDetailedThreatSituation