WoW:API GetNumGuildMembers: Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
m (Move page script moved page API GetNumGuildMembers to API GetNumGuildMembers without leaving a redirect) |
||
(11 intermediate revisions by 11 users not shown) | |||
Line 1: | Line 1: | ||
{{wowapi}} __NOTOC__ | |||
Returns the total and online number of guild members. | |||
numTotalMembers, numOnlineMaxLevelMembers, numOnlineMembers = GetNumGuildMembers(); | |||
==Parameters== | |||
[[ | ===Returns=== | ||
:;numTotalMembers | |||
:: Integer - total number of people in the guild, or 0 if player is not in a guild. | |||
:;numOnlineMaxLevelMembers | |||
:: Integer - total number of people in the guild that are at the level cap, or 0 if player is not in a guild. (Does not include remote chat members) | |||
:;numOnlineMembers | |||
:: Integer - number of online people in the guild, or 0 if the player is not in a guild. | |||
==Example== | |||
local numTotal, numOnlineMaxLevel, numOnline = GetNumGuildMembers(); | |||
DEFAULT_CHAT_FRAME:AddMessage(numTotal .. " guild members: " .. numOnline .. " online (" .. numOnlineMaxLevel .. " at maximum level), " .. (numTotal - numOnline) .. " offline."); | |||
===Result=== | |||
Displays the number of people online, offline, and the total headcount of your guild in the default chat frame. | |||
==Notes== | |||
You may need to call [[API_GuildRoster|GuildRoster()]] first in order to obtain correct data. May return wrong values immediately after quitting a guild. Maximum returned value is 1000. |
Latest revision as of 04:46, 15 August 2023
← WoW API < GetNumGuildMembers
Returns the total and online number of guild members.
numTotalMembers, numOnlineMaxLevelMembers, numOnlineMembers = GetNumGuildMembers();
Parameters[edit]
Returns[edit]
- numTotalMembers
- Integer - total number of people in the guild, or 0 if player is not in a guild.
- numOnlineMaxLevelMembers
- Integer - total number of people in the guild that are at the level cap, or 0 if player is not in a guild. (Does not include remote chat members)
- numOnlineMembers
- Integer - number of online people in the guild, or 0 if the player is not in a guild.
Example[edit]
local numTotal, numOnlineMaxLevel, numOnline = GetNumGuildMembers(); DEFAULT_CHAT_FRAME:AddMessage(numTotal .. " guild members: " .. numOnline .. " online (" .. numOnlineMaxLevel .. " at maximum level), " .. (numTotal - numOnline) .. " offline.");
Result[edit]
Displays the number of people online, offline, and the total headcount of your guild in the default chat frame.
Notes[edit]
You may need to call GuildRoster() first in order to obtain correct data. May return wrong values immediately after quitting a guild. Maximum returned value is 1000.