WoW API: GetPartyMember

From AddOn Studio
Revision as of 04:46, 15 August 2023 by Move page script (talk | contribs) (Move page script moved page API GetPartyMember to API GetPartyMember without leaving a redirect)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

WoW API < GetPartyMember

Returns 1 if the specified party member exists, nil otherwise.

memberExists = GetPartyMember(index);

Parameters[edit]

Arguments[edit]

index
Number - Which party member to query (1-4).

Returns[edit]

memberExists
Flag - If the specified party member exists, returns 1, otherwise nil.

Example[edit]

memberCount = 0
for groupindex = 1,MAX_PARTY_MEMBERS do
 if (GetPartyMember(groupindex)) then
  memberCount = memberCount + 1
 end
end

Result[edit]

Will count the number of members in the party (not the best way to do that but it's a reasonable example).