Thread Tools Display Modes
11-29-18, 03:54 PM   #1
MuffinManKen
A Flamescale Wyrmkin
AddOn Author - Click to view addons
Join Date: Dec 2009
Posts: 106
Bug in GetAchievementCriteriaInfo (8.1.0.28485 PTR)

GetAchievementNumCriteria(341) returns 1

Calling GetAchievementCriteriaInfo(341, 1) throws an error:
Code:
Message: [string "return GetAchievementCriteriaInfo(341, 1)"]:1: GetAchievementCriteriaInfo(achievementID, criteriaIndex [,countHidden]), criteria not found
Time: Thu Nov 29 16:50:55 2018
Count: 1
Stack: [string "return GetAchievementCriteriaInfo(341, 1)"]:1: GetAchievementCriteriaInfo(achievementID, criteriaIndex [,countHidden]), criteria not found
[C]: in function `GetAchievementCriteriaInfo'
[string "return GetAchievementCriteriaInfo(341, 1)"]:1: in function `func'
Interface\AddOns\Blizzard_DebugTools\Dump.lua:393: in function `DevTools_DumpCommand'
Interface\FrameXML\ChatFrame.lua:2404: in function `?'
Interface\FrameXML\ChatFrame.lua:4756: in function `ChatEdit_ParseText'
Interface\FrameXML\ChatFrame.lua:4417: in function `ChatEdit_SendText'
Interface\FrameXML\ChatFrame.lua:4453: in function `ChatEdit_OnEnterPressed'
[string "*:OnEnterPressed"]:1: in function <[string "*:OnEnterPressed"]:1>

Locals: (*temporary) = 341
(*temporary) = 1
Adding the new third parameter to GetAchievementCriteriaInfo doesn't throw an error as long as you pass 'true', but I don't see any way to know if you need to.

1) It seems that since GetAchievementCriteriaInfo's third parameter is optional, it should return nil in this case if the value is set to false or left off.
2) GetAchievementNumCriteria should have an optional parameter to determine if it counts hidden criteria.
  Reply With Quote
12-19-18, 10:29 AM   #2
arith
A Cyclonian
 
arith's Avatar
AddOn Author - Click to view addons
Join Date: May 2009
Posts: 45
It looks to be a bug with BZ.
For example, turn off all your addons, and then:
open the Achievement window, go to Dungeon & Raids -> Cataclysm Raid, and find Aberrant Behavior, click on it. For me, I will get below error:

Code:
5x ...ns\Blizzard_AchievementUI\Blizzard_AchievementUI-1.0.lua:1826: GetAchievementCriteriaInfo(achievementID, criteriaIndex [,countHidden]), criteria not found
[C]: in function `GetAchievementCriteriaInfo'
...ns\Blizzard_AchievementUI\Blizzard_AchievementUI-1.0.lua:1826: in function `AchievementObjectives_DisplayCriteria'
...ns\Blizzard_AchievementUI\Blizzard_AchievementUI-1.0.lua:1448: in function `AchievementButton_DisplayObjectives'
...ns\Blizzard_AchievementUI\Blizzard_AchievementUI-1.0.lua:1372: in function `AchievementButton_DisplayAchievement'
...ns\Blizzard_AchievementUI\Blizzard_AchievementUI-1.0.lua:1233: in function `AchievementButton_OnClick'
[string "*:OnClick"]:2: in function <[string "*:OnClick"]:1>

Locals:
(*temporary) = 5310
(*temporary) = 1
  Reply With Quote

WoWInterface » PTR » PTR UI Bugs » Bug in GetAchievementCriteriaInfo (8.1.0.28485 PTR)

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