Just a note that IsInGroup() returns true for both party and raid.
A typical check is
Code:
if IsInRaid() then
-- we're in a raid
elseif IsInGroup() then
-- we're not in a raid but we are in a group, hence party
end
Similarly GetNumGroupMembers() always returns the size of the widest group the player belongs to (raid members if in raid, party members if in party)
while GetNumSubGroupMembers() always returns the size of the narrowest group the player belongs to (Group2 members if player is in G2 in a raid, party members if in a party)