12.07.2015 Views

Wiley-World.of.Warcraft.Programming.A.Guide.and.Reference.for.Creating.WoW.Addons

Wiley-World.of.Warcraft.Programming.A.Guide.and.Reference.for.Creating.WoW.Addons

Wiley-World.of.Warcraft.Programming.A.Guide.and.Reference.for.Creating.WoW.Addons

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Chapter 27 ■ API <strong>Reference</strong> 785Returns:texture—Path to the spell’s icon texture (string)name—Name <strong>of</strong> the spell (string)isTradeskillSpell—1 if the spell is a tradeskill recipe; otherwise nil (1nil)isSpellLearned—1 if the reward teaches the player a new spell; otherwise nil(1nil)GetRewardTalentsReturns the talent points awarded when completing a quest.talents = GetRewardTalents()Only valid when the questgiver UI is showing the accept/decline orcompletion stages <strong>of</strong> a quest dialog (between the QUEST_DETAIL <strong>and</strong> QUEST_FINISHED events, or between the QUEST_COMPLETE <strong>and</strong> QUEST_FINISHEDevents); otherwise may return zero or a value from the most recently displayedquest.(Very few quests award talent points; currently this functionality is only usedwithin the Death Knight starting experience.)Returns:talents—The talent points to be awarded (number)GetRewardTextReturns questgiver dialog to be displayed when completing a quest.text = GetRewardText()Only valid when the questgiver UI is showing the completion stage <strong>of</strong> a questdialog (between the QUEST_COMPLETE <strong>and</strong> QUEST_FINISHED events);otherwise may return the empty string or a value from the most recentlydisplayed quest.Returns:text—Text to be displayed <strong>for</strong> the quest completion dialog (string)GetRewardTitleReturns the title awarded when completing a quest.title = GetRewardTitle()Only valid when the questgiver UI is showing the accept/decline orcompletion stages <strong>of</strong> a quest dialog (between the QUEST_DETAIL <strong>and</strong>QUEST_FINISHED events, or between the QUEST_COMPLETE <strong>and</strong> QUEST_FINISHED events); otherwise may return nil or a value from the most recentlydisplayed quest.Returns:title—The title to be awarded, or nil if the quest does not reward a title(string)GetRuneCooldownReturns cooldown in<strong>for</strong>mation about one <strong>of</strong> the player’s rune resources.start, duration, runeReady = GetRuneCooldown(slot)

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!