Pawn Upgrade Advisor icons not showing
trininja2k opened this issue ยท 9 comments
In WoW 7.1 there is a new API feature, IsContainerItemAnUpgrade that can display green arrows on upgrades on your item icons. The vanilla wow client doesn't use that feature atm, but Pawn uses that API feature to display the green arrows and AdiBags seems to not allow Pawn to modify the icon display to show the green arrow. Can you implement that feature in any way or better allow Pawn to modify the item icon?
add to widgets\ItemButton.lua
after Line 305:
self:IsContainerItemAnUpgrade()
and after 335:
use the function in the next comment, this one crashed on resource bank
Thank you very much, I found out how I can change the iLvL text position too and now it looks okay for me. ;)
use this funtion, the above crashed on resource depod
function buttonProto:IsContainerItemAnUpgrade()
local itemIsUpgrade = IsContainerItemAnUpgrade(self:GetParent():GetID(), self:GetID());
if ( itemIsUpgrade == nil and self.UpgradeIcon) then -- nil means not all the data was available to determine if this is an upgrade.
self.UpgradeIcon:SetShown(false);
elseif (self.UpgradeIcon) then
self.UpgradeIcon:SetShown(itemIsUpgrade);
end
end
Please help. Mind you, I'm a complete newbie and know absolutely nothing about coding, so I've managed to mess it up several times. Where exactly should I paste that code?
Am I looking at the correct part when you mention line 305?
local bag, slot = self.bag, self.slot
self.itemId = GetContainerItemID(bag, slot)
self.itemLink = GetContainerItemLink(bag, slot)
self.hasItem = not not self.itemId
self.texture = GetContainerItemInfo(bag, slot)
self.bagFamily = select(2, GetContainerNumFreeSlots(bag))
self:Update()
and second part - after buttonProto:UpdateCount function? I honestly don't know what I'm doing, thanks for help
@Xelosy:
In modules/ItemLevel.lua, Line 105:
Replace "TOPLEFT" with "BOTTOMLEFT"
Alternatively you can mess with the numbers on that line to move it to wherever you like.
How do I change where the green arrow is positioned? It's currently behind the ilevel text, I'd like it to be in the middle at the bottom.
This is a duplicate of #151.