View Single Post
02-10-16, 07:01 PM   #5
Resike
A Pyroguard Emberseer
AddOn Author - Click to view addons
Join Date: Mar 2010
Posts: 1,290
Originally Posted by SDPhantom View Post
The easiest way I can think of is to just create a static number of party frames. Changing the UnitFrame's unit after it's created may cause problems as the SecureGroupHeader will still create frames and rearrange them based on its own settings.

There is a quirk that I spotted looking at Blizzard's code. They use IsInGroup() to check if the player is in a party and from what I can dig up, should return true if in a raid as well. They don't have any seperate check in the same section to see if you're in a raid. This means if you only set the showParty attribute, it should pop up with your group in raid.

This is all in theory, don't be surprised if it doesn't work.
It's weird but it works. Tho i have to control the header's visibility manually after i force set the unit attribute, but thats not a biggy. But everything else works fine. The reason that i would like to keep the party as a secure header too, because it's much easier to arrange the frames colums/rows, horizontal/vertical party and stuff like that. Also all the other sorting method works fine like sort by name/role/class etc, which would be a pain in the ass to code with normal secure frames.

If i only use the showParty attribute the party header works fine, because it only shows up in a party and while in a party there is only one group. But i would like to give the user an option to keep the party frame shown even while in raid.

IsInGroup() could work perfectly fine if there is an IsInRaid() before it in a if-else/or statement.

Last edited by Resike : 02-10-16 at 07:09 PM.
  Reply With Quote