Quantcast
World quests - WoWInterface
Thread Tools Display Modes
06-15-17, 07:56 PM   #1
loff93
A Fallenroot Satyr
Join Date: Apr 2017
Posts: 25
World quests

Hey!
Trying to make my addon to show a specific world quest if it's active. What I do below doesn't seem to work as it's not in the QuestLog but I haven't found a function to find a World Quest without GetNumQuestLogEntries().

Code:
local function Quest_loop()
    for index = 1, GetNumQuestLogEntries(), 1 do
    local title, _, _, _, _, isComplete, _, questID = GetQuestLogTitle(index);
	
	if string.find(title, "Treasure Master Iks'reeged") or questID == 45379 then
	print(title, "is Active")
	end

    end
end
I know ingame I could just have used a macro like /dump IsQuestFlaggedCompleted(45379) or maybe a print (IsQuestFlaggedCompleted(45379))


Edit:
Ended up just using this code - since I only wanna check 1 world quest anyways.
Code:
function tore_questCheck(questID)
	local isComplete = IsQuestFlaggedCompleted(questID)
	if isComplete == false then
		print("Treasure Master Iks'reeged is Active")
	end
end

Last edited by loff93 : 06-15-17 at 08:48 PM.
  Reply With Quote
06-15-17, 11:25 PM   #2
Gethe
RealUI Developer
 
Gethe's Avatar
Premium Member
Featured
Join Date: Sep 2008
Posts: 929
World quests have their own API and are referred to as TaskQuests. Some documentation is available here. The function you might use is C_TaskQuest.IsActive(questID).
__________________
Knowledge = Power; Be OP

  Reply With Quote
06-15-17, 11:36 PM   #3
loff93
A Fallenroot Satyr
Join Date: Apr 2017
Posts: 25
Originally Posted by Gethe View Post
World quests have their own API and are referred to as TaskQuests. Some documentation is available here. The function you might use is C_TaskQuest.IsActive(questID).
Thanks for sharing!
  Reply With Quote

WoWInterface » AddOns, Compilations, Macros » AddOn Help/Support » World quests

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off