WoW API: GetLFGTypes

From AddOn Studio
Revision as of 18:22, 3 September 2006 by WoWWiki>WoWWiki-Zelgadis (part of a API redesign proposal, please don't change the layout for the next few days)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

WoW API < GetLFGTypes

Returns all available LFG categories

category1, category2, category3, ... = GetLFGTypes()

Takes

Nothing

Returns

String categoryN
Name of Nth category

Events

Needs UPDATE_LFG_TYPES

Details

When using this function to feed other LFG functions with its results, remember that these functions only want the index of the value, not the value itself. If you wanted to use 'Zone' as category, you would have to supply the number 4. Look at the example!

Example

local types = {GetLFGTypes()} for i,category in types do DEFAULT_CHAT_FRAME:AddMessage(format('Category %u: %s', i, category)) end Output: Category 1: Dungeon Category 2: Raid Category 3: Quest Category 4: Zone Category 5: Battleground

User:Zelgadis/LFG notice