WoW lua: Getting quest attributes before the QUEST_DETAIL event

Posted by Matt DiTrolio on Game Development See other posts from Game Development or by Matt DiTrolio
Published on 2011-02-03T15:08:40Z Indexed on 2011/02/03 23:35 UTC
Read the original article Hit count: 378

Filed under:
|
|

I'd like to determine the attributes of a quest (i.e., information provided by functions such as QuestIsDaily and IsQuestCompletable) before the player clicks on the quest detail.

I'm trying to write an add-on that handles accepting and completing of daily quests with a single click on the NPC, but I'm running into a problem whereby I can't find out anything about a given quest unless the quest text is currently being displayed, defeating the purpose of the add-on. Other add-ons of this nature seem to be getting around this limitation by hard-coding information about quests, an approach I don't much like as it requires constant maintenance.

It seems to me that this information must be available somehow, as the game itself can properly figure out which icon to display over the head of the NPC without player interaction. The only question is, are add-on authors allowed access to this information? If so, how?


EDIT: What I originally left out was that the situations I'm trying to address are when:

  1. An NPC has multiple quests
  2. The quest detail is not the first thing that shows up upon right-click

Otherwise, the situation is much simpler, as I have the information I need provided immediately.

© Game Development or respective owner

Related posts about world-of-warcraft

Related posts about quests