I'm trying to get expirations on certain world quests as soon as I log in. Any ideas why print() step 4 below is failing? If I wait for 10-15 sec and run lines 4-8 again from a function, it reports the minutes as expected. It also succeeds if I have been logged in for 10-15 sec and /reload. It only fails when first logging in. I have tried all of the RegisterEvent() options listed in the login sequence of the
addon loading process.
Lua Code:
local f=CreateFrame("Frame");
f:RegisterEvent("PLAYER_LOGIN");
f:SetScript("OnEvent",function(self,event,...)
print(1)
print(2,C_TaskQuest.GetQuestInfoByQuestID(65143))
print(3,GetTaskInfo(65143))
print(4,C_TaskQuest.GetQuestTimeLeftMinutes(65143))
print(5)
end);