WoW:API GetPartyMember: Difference between revisions

From AddOn Studio
Jump to navigation Jump to search
m (Fixed category link)
mNo edit summary
Line 35: Line 35:
----
----
{{Template:WoW API}}
{{Template:WoW API}}
[[Category:API Functions|GetPartyMember]]
[[Category:API Group Functions|GetPartyMember]]
[[Category:API Group Functions|GetPartyMember]]

Revision as of 18:12, 29 August 2005

GetPartyMember
memberId = GetPartyMember(id);

Returns the id of the specified party member if that party member exists, or nil otherwise.


Arguments
(id)
id
Number - Which party member to query (1-4)

Returns
memberId
memberId
Number - If the specified party member exists, returns the id of that member, otherwise returns nil

Example


 memberCount = 0
 for groupindex = 1,4 do
   if (GetPartyMember(groupindex)) then
     memberCount = memberCount + 1
   end
 end
Result
Will count the number of members in the party (not the best way to do that but it's a reasonable example).

Template:WoW API