anhility / BestInSlotRedux

A fork and continuation of the BestInSlot WoW addon.
MIT License
2 stars 15 forks source link

Added Heart of Azeroth #42

Closed dioxina closed 6 years ago

dioxina commented 6 years ago

This would add the Artifact Heart of Azeroth

Meivyn commented 6 years ago

You should fix your indentation, and some things aren't required in your code:

if slotId == 2
local _, link, _, _, _, _, _, _, _, texture = GetItemInfo(NeckItemId)

Like this you don't retrieve data you don't want from GetItemInfo(). Also brackets aren't needed. I planned to add it today, so thanks I don't have to do it anymore.

Meivyn commented 6 years ago

You don't need the last _ :)

    ----------------------Artifact Neck------------------------------------
    if slotId == 2 and self:GetSelected(self.RAIDTIER) >= 80000 and self:GetSelected(self.RAIDTIER) < 90000 then
          icon:SetUserData("disabled", true)
          button:SetDisabled(true)
          NeckItemId = 158075
          local _, link, _, _, _, _, _, _, _, texture = GetItemInfo(NeckItemId)
          icon:SetImage(texture)
          icon:SetUserData("itemid", NeckItemId)
          icon:SetUserData("itemlink", link)
          label:SetText(link)
          isLegionWeapon = true
    elseif (slotId == 16 or slotId == 17) and (self:GetSelected(self.RAIDTIER) >= 70000 and self:GetSelected(self.RAIDTIER) < 80000) then
    ----------------------Artifact weapons------------------------------------

Not sure why you does < 79999 since you do >= 80000 just before.

zoveus commented 6 years ago

thank you guys, i'll add your stuff to the addon soon as i can.

Meivyn commented 6 years ago

Don't merge our requests as they will conflict. Edit files yourself.

zoveus commented 6 years ago

okay, thank you for the hint.