Get the race of a unit.

local race = UnitRace(unit)

Parameter Edit

String - the UnitID (e.g. "player", "target", "party1", "raid1", etc..)

Returns Edit

String - returns Human or Elf
Note: if the specified unit doesn't exist, it returns nil.

Example Edit

Display the race of the player


Ad blocker interference detected!

Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.