Automated updating of API pages at this location, to reflect patch changes, has ceased from 10.1.7 onwards. |
Returns the damage stats for the unit.
lowDmg, hiDmg, offlowDmg, offhiDmg, posBuff, negBuff, percentmod = UnitDamage(unit)
Arguments[]
- unit
- string : UnitId - Likely only works for
"player"
and"pet"
. Possibly for [Beast Lore]"target"
.
Returns[]
- lowDmg
- number - The unit's minimum melee damage.
- hiDmg
- number - The unit's maximum melee damage.
- offlowDmg
- number - The unit's minimum offhand melee damage.
- offhiDmg
- number - The unit's maximum offhand melee damage. (same as above)
- posBuff
- number - positive physical Bonus (should be >= 0)
- negBuff
- number - negative physical Bonus (should be <= 0)
- percentmod
- number - percentage modifier (usually 1; 0.9 for warriors in defensive stance)
Details[]
- Doesn't seem to return usable values for mobs, NPCs. The method returns 7 values, only some of which appear to be useful.