From ESOUI Wiki
Checks the item in a particular bag slot and returns its armor type (light/medium/heavy/none), as an ArmorType constant.
- A number representing the bag to check; it must be one of the built-in Bag values.
- The numeric index of the slot in that bag which should be checked. For most bags, this is a number ranging from 1 to the size of the bag.
local armorType = GetItemArmorType(bagId, slotIndex)
if armorType == ARMORTYPE_HEAVY then
d("That's heavy armor!")