WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   Wish List (https://www.wowinterface.com/forums/forumdisplay.php?f=15)
-   -   Implement QUEST_LOG_CRITERIA_UPDATE (https://www.wowinterface.com/forums/showthread.php?t=56622)

MuffinManKen 08-31-18 10:28 AM

Implement QUEST_LOG_CRITERIA_UPDATE
 
This event is in the new documentation, but after going through UI code and extensive use of eventtrace I can't seem to detect any trace of its existence. An event telling us that a given quest has had it's criteria updated would be very handy since otherwise you have to jump through a bunch of hoops to get this info.

Xrystal 08-31-18 10:45 AM

Quote:

Originally Posted by MuffinManKen (Post 329935)
This event is in the new documentation, but after going through UI code and extensive use of eventtrace I can't seem to detect any trace of its existence. An event telling us that a given quest has had it's criteria updated would be very handy since otherwise you have to jump through a bunch of hoops to get this info.

In addition to my response to your previous this one as far as I have always known it to be ( they may have removed it since Legion started ) has always acted on quests with criteria to complete.

EG. Ancient Mana has the criteria of 3/3 Ancient Mana Nodes to find. Each trigger of that event will update the first number until it reaches the required number and inform you that the quest is completed via QUEST_COMPLETE I think if memory serves.

Xrystal 08-31-18 10:50 AM

It does indeed appear to be that they have removed that event from the game, I just tried it on the world quest that has the squirrels and nuts and the event didn't trigger. I definitely recall in the past this was working for the regular quests. So time to check those out just in case they don't work with world quests.

Also, just noticed that even QUEST_COMPLETE doesn't trigger. Did they remove these and forgot to remove them from the documentation I wonder .

QUEST_WATCH_UPDATE also doesn't trigger despite actively working on a quest being watched and listed in my objective tracker.

It does look like using QUEST_LOG_UPDATE in combination with other functions are the only way to go ..

MuffinManKen 08-31-18 12:06 PM

QUEST_COMPLETE does fire, but it's not firing to say the quest can be turned in. It's part of the GOSSIP/Quest giver bit. When you click continue on the Quest dialog while handing it in, that's when it fires. It doesn't have the best name.

Xrystal 08-31-18 12:54 PM

Quote:

Originally Posted by MuffinManKen (Post 329943)
QUEST_COMPLETE does fire, but it's not firing to say the quest can be turned in. It's part of the GOSSIP/Quest giver bit. When you click continue on the Quest dialog while handing it in, that's when it fires. It doesn't have the best name.

Yeah I just found that out myself.

Seerah 08-31-18 04:06 PM

As of my last export (Aug. 7) this event is registered for and referenced in QuestMapFrame.lua

Xrystal 08-31-18 04:49 PM

Quote:

Originally Posted by Seerah (Post 329950)
As of my last export (Aug. 7) this event is registered for and referenced in QuestMapFrame.lua

I initially said that too, as I used to use it myself, but I can confirm that despite it being used in blizzard code, we can't seem to use it in our addons. I have done several world quests, emissary quests and regular levelling quests and it never triggered once at all today. So maybe they have it in their code still but it never triggers either. It's not like they haven't left redundant code in there before :)

Lua Code:
  1. elseif ( event == "QUEST_LOG_CRITERIA_UPDATE" ) then
  2.     local questID, criteriaID, description, fulfilled, required = ...;
  3.  
  4.     if (QuestMapFrame_CheckQuestCriteria(questID, criteriaID, description, fulfilled, required)) then
  5.       UIErrorsFrame:AddMessage(ERR_QUEST_ADD_FOUND_SII:format(description, fulfilled, required), YELLOW_FONT_COLOR:GetRGB());
  6.     end

Xrystal 09-01-18 05:54 AM

Quote:

Originally Posted by LanceDH (Post 329953)
Bit off topic, but am I wrong in saying CVAR_UPDATE also doesn't trigger as it should?
It's used in many of Blizzard's lua files, but it doesn't show up in the eventtrace and doesn't seem to trigger in add-ons.

It does trigger but only if the 3rd parameter of the SetCVar function is set.

EG.

Changing the Display Honor as Experience Bar doesn't trigger the CVAR_UPDATE because in their code they haven't done something along the lines of SetCVarBool("HonorAsExperience",true,"HONOR_AS_EXPERIENCE"). That third parameter would be what you test for on the CVAR_UPDATE event.

However, if you adjust the option setting to always display action bars ( this will show the outline of the buttons without icons in ), it will trigger the CVAR_UPDATE with the argument "ALWAYS_SHOW_MULTIBARS_TEXT" which is the 3rd value when they set their CVAR with SetCVarBool("alwaysShowActionBars",true,"ALWAYS_SHOW_MULTIBARS_TEXT")

LanceDH 09-01-18 07:39 AM

Ye I noticed the specific buttons in Blizzard's UI I was testing with didn't have the third argument filled in, hence why I deleted the comment.


All times are GMT -6. The time now is 10:43 PM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI