Skip to content
This repository has been archived by the owner on Nov 8, 2017. It is now read-only.

Error when items are unequipped #2

Open
nasapunk88 opened this issue Oct 17, 2014 · 1 comment
Open

Error when items are unequipped #2

nasapunk88 opened this issue Oct 17, 2014 · 1 comment

Comments

@nasapunk88
Copy link

Currently if you are missing any item (using a 2h, missing offhand) it error's out.
The problem is that itemString is nil when there is no equipped item and is then passed to "GetItemInfo(itemString)", causing the error.
A quick fix is just making sure there is an item equipped before calling the function,
inside ItemLevelOverlay.lua, line 24:

local function getInventoryItemLevelFromInventorySlotName(inventorySlotName)
local inventorySlotNumber = select(1, GetInventorySlotInfo(inventorySlotName))
local inventoryItemLink = GetInventoryItemLink("player", inventorySlotNumber)
if inventoryItemLink then
return ItemUpgradeInfo:GetUpgradedItemLevel(inventoryItemLink)
else
return nil
end
end

@lucianahanan
Copy link

I'm with every slot equiped here, and the problem still happen. Every time, on ui load. Might be that and something else.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants