diff --git a/ItemRack/ItemRack.lua b/ItemRack/ItemRack.lua index 2763387..c10b6d7 100644 --- a/ItemRack/ItemRack.lua +++ b/ItemRack/ItemRack.lua @@ -77,6 +77,12 @@ ItemRackItems = { ["25653"] = { keep=1 }, -- riding crop } +ItemRack.NoTitansGrip = { + ["Polearms"] = 1, + ["Fishing Poles"] = 1, + ["Staves"] = 1 +} + ItemRack.Menu = {} ItemRack.LockList = {} -- index -2 to 11, flag whether item is tagged already for swap if ItemRack.IsClassic() then @@ -389,6 +395,17 @@ function ItemRack.UpdateClassSpecificStuff() if class=="WARRIOR" or class=="ROGUE" or class=="HUNTER" or class=="MAGE" or class=="WARLOCK" or class=="SHAMAN" or class=="DEATHKNIGHT" then ItemRack.CanWearOneHandOffHand = 1 end + + if ItemRack.IsWrath() and class=="WARRIOR" then + if select(5,GetTalentInfo(2,26))>0 then + ItemRack.HasTitansGrip = 1 + ItemRack.SlotInfo[17].INVTYPE_2HWEAPON = 1 + else + ItemRack.HasTitansGrip = nil + ItemRack.SlotInfo[17].INVTYPE_2HWEAPON = nil + end + end + end function ItemRack.OnSetBagItem(tooltip, bag, slot) @@ -1327,7 +1344,7 @@ function ItemRack.EquipItemByID(id,slot) if not isLocked and not IsInventoryItemLocked(slot) then -- neither container item nor inventory item locked, perform swap local _,_,equipSlot = ItemRack.GetInfoByID(id) - if equipSlot~="INVTYPE_2HWEAPON" or not GetInventoryItemLink("player",17) then + if equipSlot~="INVTYPE_2HWEAPON" or (ItemRack.HasTitansGrip and not ItemRack.NoTitansGrip[select(7,GetItemInfo(GetContainerItemLink(b,s))) or ""]) or not GetInventoryItemLink("player",17) then PickupContainerItem(b,s) PickupInventoryItem(slot) else