WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   WoD Beta archived threads (https://www.wowinterface.com/forums/forumdisplay.php?f=151)
-   -   ObjectivesTrackerFrame Info (https://www.wowinterface.com/forums/showthread.php?t=49496)

Xrystal 07-19-14 05:43 PM

ObjectivesTrackerFrame Info
 
I'll update this as I get hold of the new information but here is a bit of the contents of the ObjectivesTrackerFrame. I only drilled 7 levels down but it looks like the latter levels are of the same ilk as the earlier ones.

Lua Code:
  1. ObjectivesTrackerFrame
  2. |_0 : userdata
  3. |_initialized : Boolean
  4. |_watchMoneyReasons : Number
  5. |_inMicroDungeon : Boolean
  6. |_HeaderMenu : Table
  7. | |_0 : userdata
  8. | |_Title : Table
  9. | | |_0 : userdata
  10. | |_MinimiseButton
  11. | | |_0 : userdata
  12. |_BlockDropDown : Table
  13. | |_0 : userdata
  14. | |_displayMode : String
  15. |_MODULES : Table
  16. | |_1 : Table
  17. | | |_blockOffsetX : Number
  18. | | |_updateReasonEvents : Number
  19. | | |_fromHeaderOffsetY : Number
  20. | | |_updateReasonModule : Number
  21. | | |_Header : Table ( see below - marked H1)
  22. | | |_StaticReanchor : Function
  23. | | |_Update : Function
  24. | |_2 : Table
  25. | | |_contentsHeight : Number
  26. | | |_blockTemplate : String (AutoQuestPopUpBlockTemplate)
  27. | | |_hasSkippedBlocks : Boolean
  28. | | |_oldContentsHeight : Number
  29. | | |_blockType : String (ScrollFrame)
  30. | | |_contentsAnimHeight : Number
  31. | | |_blockOffsetX : Number
  32. | | |_blockOffsetY : Number
  33. | | |_updateReasonEvents : Number
  34. | | |_updateReasonModule : Number
  35. | | |_OnFreeBlock : Function
  36. | | |_Update : Function
  37. | | |_Header : Table ( see below - marked H2 )
  38. | | |_usedBlocks : Table
  39. | | |_freeBlocks : Table
  40. | |_3 : Table
  41. | | |_updateReasonModule : Number
  42. | | |_contentsAnimHeight : Number
  43. | | |_updateReasonEvents : Number
  44. | | |_hasSkippedBlocks : Boolean
  45. | | |_oldContentsHeight : Number
  46. | | |_contentsHeight : Number
  47. | | |_Header : Table ( see below - marked H3)
  48. | | |_usedBlocks : Table
  49. | | |_freeItemButtons : Table
  50. | | |_OnFreeBlock : Function
  51. | | |_OnBlockHeaderClick : Function
  52. | | |_OnFreeTypedLine : Function
  53. | | |_Update : Function
  54. | | |_SetBlockHeader : Function
  55. | |_4 : Table
  56. | | |_blockOffsetX : Number
  57. | | |_blockOffsetY : Number
  58. | | |_lineTemplate : String (BonusObjectiveTrackerLineTemplate)
  59. | | |_blockTemplate : String (BonusObjectiveTrackerBlockTemplate)
  60. | | |_blockPadding : Number
  61. | | |_oldContentsHeight : Number
  62. | | |_fromHeaderOffsetY : Number
  63. | | |_blockType : String (ScrollFrame)
  64. | | |_updateReasonEvents : Number
  65. | | |_hasSkippedBlocks : Boolean
  66. | | |_contentsHeight : Number
  67. | | |_updateReasonModule : Number
  68. | | |_contentsAnimHeight : Number
  69. | | |_freeLines : Table
  70. | | |_usedBlocks : Table
  71. | | |_freeBlocks : Table
  72. | | |_Header : Table ( see below - marked H4 )
  73. | | |_Update : Function
  74. | | |_OnFreeBlock : Function
  75. | | |_OnFreeLine : Function
  76. | | |_AddProgressBar : Function
  77. | | |_FreeProgressBar : Function
  78. | | 5 : Table
  79. | | |_contentsHeight : Number
  80. | | |_updateReasonModule : Number
  81. | | |_contentsAnimHeight : Number
  82. | | |_oldContentsHeight : Number
  83. | | |_updateReasonEvents : Number
  84. | | |_Header : Table ( see below - marked H5)
  85. | | |_usedBlocks : Table
  86. | | |_Update : Function
  87. | | |_OnBlockHeaderClick : Function
  88. |_BlocksFrame : Table
  89. | |_0 : userData
  90. | |_poiTable : Table
  91. | | |_completed : Table
  92. | | |_numeric : Table
  93. | | | |_0 : userdata
  94. | | | |_NormalTexture : userdata
  95. | | | |_Glow : userdata
  96. | | | |_PushedTexture : userdata
  97. | | | |_HighlightTexture : userdata
  98. | | | |_index : Number
  99. | | | |_storyQuest : Boolean
  100. | | | |_style : String
  101. | | | |_used : Boolean
  102. | | | |_selected : Boolean
  103. | | | |_questId : Numeric
  104. | |_contentsHeight : Number
  105. | |_maxHeight : Number
  106. | |_ScenarioHeader : Table (see below - under Header - marked SH)
  107. | |_AchievementHeader : Table (see below - under Header - marked AH)
  108. | |_currentBlock : Table (see below - under Header - marked CB)
  109. | |_QuestHeader : Table (see below - under Header - marked QH)
  110. | |_poiOnCreateFunc : Function

Header Block Contents (H1 - H5 done, SH,AH,CB,QH to do )
Lua Code:
  1. |_0 : userdata ( H1 H2 H3 H4 H5 )
  2. |_SoftGlow : Table ( H1 H2 H3 H4 H5 )
  3. | |_0 : userdata
  4. |_HeaderOpenAnim : Table ( H1 H2 H3 H4 H5 )
  5. | |_0 : userdata
  6. |_animateReason : Number ( H1 H2 H3 H4 H5 )
  7. |_LineSheen : Table ( H1 H2 H3 H4 H5 )
  8. | |_0 : userdata
  9. |_isHeader : Boolean ( H1 H2 H3 H4 H5 )
  10. |_LineGlow : Table ( H1 H2 H3 H4 H5 )
  11. | |_0 : userdata
  12. |_Background : Table ( H1 H2 H3 H4 H5 )
  13. | |_0 : userdata
  14. |_height : Number ( H1 H2 H3 H4 H5 )
  15. |_onFinishUpdateReason : Number ( H1 H2 H3 H4 H5 )
  16. |_StarBurst : Table ( H1 H2 H3 H4 H5 )
  17. | |_0 : userdata
  18. |_Text : Table ( H1 H2 H3 H4 H5 )
  19. | |_0 : userdata
  20. |_added : Boolean ( H2 H3 )
  21. |_animating : Boolean ( H2 H3 )
  22. |_BottomShadow : Table ( H4 )
  23. | |_0 : userdata
  24. |_TopShadow : Table ( H4 )
  25. | |_0 : userdata
  26. |_ShadowAnim : Table ( H4 )
  27. | |_0 : userdata
  28. | |_TransAnim : Table
  29. | |  |_0 : userdata
  30. |
  31. |_module : Table ( H1 )
  32. | |_blockOffsetX : Number
  33. | |_Update : Function
  34. | |_updateReasonEvents : Number
  35. | |_Header : Table
  36. | |_StaticReanchor : Function
  37. | |_fromHeaderOffsetY : Number
  38. | |_updateReasonModule : Number
  39. |
  40. |_module : Table ( H2 H3 )
  41. | |_OnFreeBlock : Function
  42. | |_OnBlockHeaderClick : Function
  43. | |_OnFreeTypedLine : Function
  44. | |_freeItemButtons : Function
  45. | |_Update : Function
  46. | |_updateReasonModule : Number
  47. | |_contentsAnimHeight : Number
  48. | |_updateReasonEvents : Number
  49. | |_hasSkippedBlocks : Boolean
  50. | |_usedBlocks : Table
  51. | |_oldContentsHeight : Number
  52. | |_contentsHeight : String
  53. | |_SetBlockHeader : Function
  54. | |_Header : Table
  55. |
  56. |_module : Table ( H4 )
  57. | |_OnFreeBlock : Function
  58. | |_lineTemplate : String (BonusObjectiveTrackerLineTemplate)
  59. | |_freeBlocks : Table
  60. | |_blockOffsetX : Number
  61. | |_Update : Function
  62. | |_OnFreeLine : Function
  63. | |_blockTemplate : String (BonusObjectiveTrackerBlockTemplate)
  64. | |_blockPadding : Number
  65. | |_usedBlocks : Table
  66. | |_oldContentsHeight : Number
  67. | |_fromHeaderOffsetY : Number
  68. | |_AddProgressBar : Function
  69. | |_blockType : String (ScrollFrame)
  70. | |_blockOffsetY : Number
  71. | |_updateReasonEvents : Number
  72. | |_hasSkippedBlocks : Boolean
  73. | |_Header : Table
  74. | |_FreeProgressBar : Function
  75. | |_freeLines : Table
  76. | |_contentsHeight : String
  77. | |_contentsAnimHeight : Number
  78. | |_updateReasonModule : Number
  79. |
  80. |_module : Table ( H5 )
  81. | |_contentsHeight : String
  82. | |_Update : Function
  83. | |_contentsAnimHeight : Number
  84. | |_hasSkippedBlocks : Boolean
  85. | |_usedBlocks : Table
  86. | |_oldContentsHeight : Number
  87. | |_OnBlockHeaderClick : Function
  88. | |_updateReasonModule : Number
  89. | |_updateReasonEvents : Number

liquidbase 07-23-14 04:35 AM

In DuffedUI v7 I work with the WatchFrameDropDown_Initialize function to generate a wowhead link for quests or achievements. With Warlords of Draenor that is now no longer function. So far I have found nothing that would replace this function. Could possibly someone help me identify the correct function?

Lua Code:
  1. function ObjectiveTracker:WOWHead()
  2.     -- Quest / achievement link URLs
  3.     local lST = "Wowhead"
  4.     local lQ = "http://www.wowhead.com/quest=%d"
  5.     local lA = "http://www.wowhead.com/achievement=%d"
  6.    
  7.     _G.StaticPopupDialogs["WATCHFRAME_URL"] = {
  8.         text = lST .. " link",
  9.         button1 = OKAY,
  10.         timeout = 0,
  11.         whileDead = true,
  12.         hasEditBox = true,
  13.         editBoxWidth = 350,
  14.         OnShow = function(self, ...) self.editBox:SetFocus() end,
  15.         EditBoxOnEnterPressed = function(self) self:GetParent():Hide() end,
  16.         EditBoxOnEscapePressed = function(self) self:GetParent():Hide() end,
  17.     }
  18.    
  19.     local tblDropDown = {}
  20.     hooksecurefunc("WatchFrameDropDown_Initialize", function(self)
  21.         if self.type == "QUEST" then
  22.             tblDropDown = {
  23.                 text = lST .. " link",
  24.                 notCheckable = true,
  25.                 arg1 = self.index,
  26.                 func = function(_, watchId)
  27.                     local logId = GetQuestIndexForWatch(watchId)
  28.                     local _, _, _, _, _, _, _, _, questId = GetQuestLogTitle(logId)
  29.                     local inputBox = StaticPopup_Show("WATCHFRAME_URL")
  30.                     inputBox.editBox:SetText(lQ:format(questId))
  31.                     inputBox.editBox:HighlightText()
  32.                 end
  33.             }
  34.             UIDropDownMenu_AddButton(tblDropDown, UIDROPDOWN_MENU_LEVEL)
  35.         elseif self.type == "ACHIEVEMENT" then
  36.             tblDropDown = {
  37.                 text = lST .. " link",
  38.                 notCheckable = true,
  39.                 arg1 = self.index,
  40.                 func = function(_, id)
  41.                     local inputBox = StaticPopup_Show("WATCHFRAME_URL")
  42.                     inputBox.editBox:SetText(lA:format(id))
  43.                     inputBox.editBox:HighlightText()
  44.                 end
  45.             }
  46.             UIDropDownMenu_AddButton(tblDropDown, UIDROPDOWN_MENU_LEVEL)
  47.         end
  48.     end)
  49.     UIDropDownMenu_Initialize(WatchFrameDropDown, WatchFrameDropDown_Initialize, "MENU")
  50. end

Lua error
Lua Code:
  1. Message: ...ce\AddOns\DuffedUI\modules\misc\objectivetracker.lua:68: hooksecurefunc(): WatchFrameDropDown_Initialize is not a function
  2. Time: 07/23/14 12:40:15
  3. Count: 1
  4. Stack: [C]: in function `hooksecurefunc'
  5. ...ce\AddOns\DuffedUI\modules\misc\objectivetracker.lua:68: in function `WOWHead'
  6. Interface\AddOns\DuffedUI\modules\misc\core.lua:19: in function <Interface\AddOns\DuffedUI\modules\misc\core.lua:5>
  7.  
  8. Locals:

Thanks for all help :)

ObbleYeah 07-23-14 08:42 AM

https://github.com/tekkub/wow-ui-sou...iveTracker.lua

you want one of the ones here I think. Possibly the one on line 33? They've given the tracker a pretty dramatic overhaul so you might need more of an extensive overwrite than just switching the functions though.

liquidbase 07-23-14 09:35 AM

Thanks that was what I was looking for.The function I need is QuestObjectiveTracker_OnOpenDropDown from line 222. Thanks for the good hint :)


All times are GMT -6. The time now is 05:49 AM.

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