Coder Social home page Coder Social logo

elvui_equipmentsetsdt's Introduction

  • ๐Ÿ‘‹ Hi, Iโ€™m @cr4ckp0t
  • ๐Ÿ‘€ Iโ€™m interested in systems administration and scripting.
  • ๐ŸŒฑ Iโ€™m currently learning PHP/Laravel.
  • ๐Ÿ’ž๏ธ Iโ€™m looking to collaborate on ...
  • ๐Ÿ“ซ How to reach me https://adamko.ch.

elvui_equipmentsetsdt's People

Contributors

cr4ckp0t avatar

Watchers

 avatar

elvui_equipmentsetsdt's Issues

bugs (and bugfixes) for gearset indexing and string color coding

There are a few bugs that I've been fixing on my local version of the addon for a few weeks now that I finally decided I would submit issues for, so that I stop having to reimplement them every time. I'm attaching my file to this post so you can diff it to see what I've changed.

ElvUI_EquipmentSetsDT.txt

  1. The Blizzard API for gearsets is busted (you have a comment implying as much), but not in the way that your indexing fixes, or at least not on the characters I tested.

    The problem is that Blizzard doesn't compress the array that they save gearsets into after you delete one, and it always adds a new gearset to the first empty index. You can recreate this test by doing the following on a new character:

    i. Create gearsets A, B, C. The gearset array will be a[0] = A, a[1] = B, a[2] = C
    ii. Delete gearset B. The gearset array will be a[0] = A, a[1]= null, a[2] = C
    iii. Create gearset D. The gearset array will be a[0] = A, a[1] = D, a[2] = C
    

    In practice, this means that a) the wacky local minimum and local maximums don't do the right thing and aren't necessary [anymore?], and b) a for loop that goes from 0 to getNumEquipmentSets() is not guaranteed to find all sets. In Step (ii) above, for example, numSets will be 2, and the for loop will only check a[0] and a[1], only finding gearset A. Instead, you need to iterate over the GetEquipmentSetInfo(i) array starting at i = 0 and ending once you've found the same number of gearsets that getNumEquipmentSets() returns. I did this with separate variables for 'i' and 'found sets' in a while loop.

  2. After the hexColor change, there are many places where "|cff" is being appended to strings. Seems like |cff is necessary for color but not hexColor, and so places where they were being used interchangeably are bugged? I went through and just tried to remove |cff from "|cff%s" any place I saw hexColor being used (and had to add |cff to the front of a few places where color was also being used in the same spot). I'm not sure what's going on under the hood on the color stuff, though, so I may have missed some, or there may be a simpler/more robust way to fix it. The attached code doesn't have any buggy color/text fields on my personal testing/setup, though.

Error when opening options menu

Hey. Probably not a big issue but receiving this error when I go to the options menu for EquipmentSetsDT. No issues when changing gear or during log on.

ElvUI : v12.03
AddOn Skins : v4.46
Equipment Sets Datatext : v4.0.0

Time: Mon Oct 19 17:40:26 2020
Count: 1
Stack: ...dOns\ElvUI_EquipmentSetsDT\ElvUI_EquipmentSetsDT.lua:357: table index is nil
[string "=(tail call)"]: ?
[string "@Interface\AddOns\ElvUI_EquipmentSetsDT\ElvUI_EquipmentSetsDT.lua"]:357: in function `member'
[string "@Interface\AddOns\ElvUI_OptionsUI\Libraries\Ace3\AceConfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua"]:221: in function <...nfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua:169>
[string "@Interface\AddOns\ElvUI_OptionsUI\Libraries\Ace3\AceConfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua"]:1288: in function <...nfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua:1160>
[string "@Interface\AddOns\ElvUI_OptionsUI\Libraries\Ace3\AceConfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua"]:1187: in function <...nfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua:1160>
[string "@Interface\AddOns\ElvUI_OptionsUI\Libraries\Ace3\AceConfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua"]:1750: in function `FeedGroup'
[string "@Interface\AddOns\ElvUI_OptionsUI\Libraries\Ace3\AceConfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua"]:1675: in function <...nfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua:1659>
[string "=[C]"]: ?
[string "@Interface\AddOns\AddOnSkins\Libs\Ace3\AceGUI-3.0\AceGUI-3.0.lua"]:72: in function <...ddOns\AddOnSkins\Libs\Ace3\AceGUI-3.0\AceGUI-3.0.lua:70>
[string "@Interface\AddOns\AddOnSkins\Libs\Ace3\AceGUI-3.0\AceGUI-3.0.lua"]:306: in function `Fire'
[string "@Interface\AddOns\AddOnSkins\Libs\Ace3\AceGUI-3.0\widgets\AceGUIContainer-TreeGroup.lua"]:526: in function `Select'
[string "@Interface\AddOns\AddOnSkins\Libs\Ace3\AceGUI-3.0\widgets\AceGUIContainer-TreeGroup.lua"]:534: in function `SelectByValue'
[string "@Interface\AddOns\ElvUI_OptionsUI\Libraries\Ace3\AceConfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua"]:1846: in function `FeedGroup'
[string "@Interface\AddOns\ElvUI_OptionsUI\Libraries\Ace3\AceConfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua"]:1675: in function <...nfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua:1659>
[string "=[C]"]: ?
[string "@Interface\AddOns\AddOnSkins\Libs\Ace3\AceGUI-3.0\AceGUI-3.0.lua"]:72: in function <...ddOns\AddOnSkins\Libs\Ace3\AceGUI-3.0\AceGUI-3.0.lua:70>
[string "@Interface\AddOns\AddOnSkins\Libs\Ace3\AceGUI-3.0\AceGUI-3.0.lua"]:306: in function `Fire'
[string "@Interface\AddOns\AddOnSkins\Libs\Ace3\AceGUI-3.0\widgets\AceGUIContainer-TreeGroup.lua"]:526: in function `Select'
[string "@Interface\AddOns\AddOnSkins\Libs\Ace3\AceGUI-3.0\widgets\AceGUIContainer-TreeGroup.lua"]:534: in function `SelectByValue'
[string "@Interface\AddOns\ElvUI_OptionsUI\Libraries\Ace3\AceConfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua"]:1846: in function `FeedGroup'
[string "@Interface\AddOns\ElvUI_OptionsUI\Libraries\Ace3\AceConfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua"]:2030: in function <...nfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua:1953>
[string "=[C]"]: in function `Open'
[string "@Interface\AddOns\ElvUI_OptionsUI\Libraries\Ace3\AceConfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua"]:1887: in function <...nfig-3.0\AceConfigDialog-3.0\AceConfigDialog-3.0.lua:1859>

Locals: <none>```

Missing entry for 'Equipment Sets'

Message: AceLocale-3.0: ElvUI_EquipmentSetsDT: Missing entry for 'Equipment Sets'
Time: Sun Jul 12 00:42:06 2020
Count: 1
Stack: AceLocale-3.0: ElvUI_EquipmentSetsDT: Missing entry for 'Equipment Sets'
[string "@interface\AddOns\ElvUI_EquipmentSetsDT\ElvUI_EquipmentSetsDT.lua"]:406: in main chunk

Locals:

lua error after deleting an equipment set

This worked great until I deleted an equipment set I no longer needed. Now when I right click on the datatext, I get the following error:

Message: ...dOns\ElvUI_EquipmentSetsDT\ElvUI_EquipmentSetsDT.lua:176: attempt to compare number with nil
Time: Mon Apr 27 12:42:32 2020
Count: 2
Stack: ...dOns\ElvUI_EquipmentSetsDT\ElvUI_EquipmentSetsDT.lua:176: attempt to compare number with nil
[string "=[C]"]: ?
[string "@Interface\AddOns\ElvUI_EquipmentSetsDT\ElvUI_EquipmentSetsDT.lua"]:176: in function `onClick'
[string "@Interface\AddOns\ElvUI\Modules\datatexts\DataTexts.lua"]:228: in function <...terface\AddOns\ElvUI\Modules\datatexts\DataTexts.lua:226>

Note that I still get this error even after uninstalling the addon and reinstalling.

Broke by ElvUI 13.18

ElvUI 13.18 and following versions broke this, probabbly because of this on change log: Datatexts added through LibDataBroker will now start with LDB.

Error: the datatext still can be selected, but it is invisble, hovering over it still gives tooltip, left clicking still opens the character sheet and right clicing still gives the selection menu.

No LUA error generated, may be connected to an issue tracked on elvui's github: tukui-org/ElvUI#767 (comment)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.