WoW:API GetChannelDisplayInfo: Difference between revisions

From AddOn Studio
Jump to navigation Jump to search
mNo edit summary
m (Move page script moved page API GetChannelDisplayInfo to API GetChannelDisplayInfo without leaving a redirect)
 
(No difference)

Latest revision as of 04:45, 15 August 2023

WoW API < GetChannelDisplayInfo

Retrieves channels (and category headers) that would be displayed in Blizzards ChannelFrame.

name, header, collapsed, channelNumber, count, active, category, voiceEnabled, voiceActive = GetChannelDisplayInfo(i);

Parameters[edit]

Arguments[edit]

id
item id (ChannelFrame can display a combined maximum of 20 channels and headers; see MAX_CHANNEL_BUTTONS and use API GetNumDisplayChannels)

Returns[edit]

name
(for channels) channel name
(for headers) name of the header
header
true if this item is a header (e.g. for category "CHANNEL_CATEGORY_WORLD")
collapsed
(for headers) true if subchannels are hidden (header is collapsed)
channelNumber
(for channels) channel number
count
(for channels) number of players in this channel
(for headers) number of subchannels beneath this header
active
(for channels) true if channel is active (if you leave a city where you were in Trade Channel the channel will remain as inactive)
category
(for channels) "CHANNEL_CATEGORY_WORLD", "CHANNEL_CATEGORY_GROUP" or "CHANNEL_CATEGORY_CUSTOM"
voiceEnabled
true if voice is enabled for this channel
voiceActive
true if voice is currently active (someone is speaking)

Note

I didn't test this function in detail. But it looks very powerful and could help keeping an eye on joined channels.
Just look into ChannelFrame.lua for more information.