View Single Post
Unread 12-01-12, 04:11 PM   #2
Baanano
Bomani Harbinger
AddOn Author - Click to view addons
Join Date: Mar 2012
Posts: 5
According to the Addon API documentation of Inspect.Item.Detail:

Code:
stats:  The base stats of this item. Members may include "block",  "critAttack", "critSpell", "deflect", "dexterity", "dodge", "endurance",  "energyMax", "energyRegen", "focus", "hit", "intelligence", "manaMax",  "manaRegen", "movement", "parry", "powerAttack", "powerMax",  "powerRegen", "powerSpell", "resistAir", "resistDeath", "resistEarth",  "resistFire", "resistLife", "resistWater", "stealth", "stealthDetect",  "strength", "wisdom", "xp", "valor", "toughness", and "vengeance".
For your strength example it would be:

Code:
local itemStrength = Inspect.Item.Detail(item).stats.strength
Or, to do it safely:

Code:
local itemDetail = Inspect.Item.Detail(item)
local itemStrength = itemDetail and itemDetail.stats and itemDetail.stats.strength or 0
Baanano is offline   Reply With Quote