WoW API type: TitleId

From AddOn Studio
Jump to navigation Jump to search

Warning: Display title "WoW API type: TitleId" overrides earlier display title "titleID".API types

titleID API Type (Number)

titleIDs are used for retrieving and setting the player's displayed title, e.g. "Champion of the Naaru" or "Private"

They are indices from 1 to GetNumTitles().

The titleIDs as of 3.0.2 are

1: Private
2: Corporal
3: Sergeant
4: Master Sergeant
5: Sergeant Major
6: Knight
7: Knight-Lieutenant
8: Knight-Captain
9: Knight-Champion
10: Lieutenant Commander
11: Commander
12: Marshal
13: Field Marshal
14: Grand Marshal
15: Scout
16: Grunt
17: Sergeant
18: Senior Sergeant
19: First Sergeant
20: Stone Guard
21: Blood Guard
22: Legionnaire
23: Centurion
24: Champion
25: Lieutenant General
26: General
27: Warlord
28: High Warlord
29: Gladiator
30: Duelist
31: Rival
32: Challenger
33: Scarab Lord
34: Conqueror
35: Justicar
36: Champion of the Naaru
37: Merciless Gladiator
38: of the Shattered Sun
39: Hand of A'dal
40: Vengeful Gladiator
41: Battlemaster
42: the Seeker
43: Elder
44: Flame Warden
45: Flame Keeper
46: the Exalted
47: the Explorer
48: the Diplomat
49: Brutal Gladiator
50: Arena Master
51: Salty
52: Chef
53: the Supreme
54: of the Ten Storms
55: of the Emerald Dream
56: Crusader
57: Prophet
58: the Malefic
59: Stalker
60: of the Ebon Blade
61: Archmage
62: Warbringer
63: Assassin
64: Grand Master Alchemist
65: Grand Master Blacksmith
66: Iron Chef
67: Grand Master Enchanter
68: Grand Master Engineer
69: Doctor
70: Grand Master Angler
71: Grand Master Herbalist
72: Grand Master Scribe
73: Grand Master Jewelcrafter
74: Grand Master Leatherworker
75: Grand Master Miner
76: Grand Master Skinner
77: Grand Master Tailor
78: of Quel'Thalas
79: of Argus
80: of Khaz Modan
81: of Gnomeregan
82: the Lion Hearted
83: Champion of Elune
84: Hero of Orgrimmar
85: Plainsrunner
86: of the Darkspear
87: the Forsaken
88: the Magic Seeker
89: Twilight Vanquisher
90: Conqueror of Naxxramas
91: Hero of Northrend
92: the Hallowed
93: Loremaster
94: of the Alliance
95: of the Horde
96: the Flawless Victor
97: Champion of the Frozen Wastes
98: Ambassador
99: the Argent Champion
100: Guardian of Cenarius
101: Brewmaster
102: Merrymaker
103: the Love Fool
104: Matron
105: Patron
106: Obsidian Slayer
107: of the Nightfall
108: the Immortal
109: the Undying
110: Jenkins
111: Bloodsail Admiral
112: nil

GetNumTitles returns 112, but GetTitleName returns nil for the 112th title.

Printing titleIDs for debug

This simple script code will iterate through the title IDs and display them in the default chat window

for i = 1, GetNumTitles() do
    DEFAULT_CHAT_FRAME:AddMessage(i.." "..(GetTitleName(i) or "nil"))
end