API UnitCreatureFamily

Returns the creature family of the specified unit (e.g., "Crab" or "Wolf"). Only works on Beasts and Demons, since the family's only function is to determine what abilities the unit will have if a hunter or warlock tames it; however, works on most currently untameable Beasts for reasons of backward and forward compatibility. Returns nil if the creature isn't a Beast or doesn't belong to a family that includes a tameable creature. creatureFamily = UnitCreatureFamily(unit);

Arguments

 * unit : UnitId - unit you wish to query.

Returns

 * creatureFamily : String - localized name of the creature family (e.g., "Crab" or "Wolf"). Possible English values are:

Example
if ( UnitCreatureFamily("target") == "Bear" ) then message("It's a godless killing machine! Run for your lives!"); end

Result
Displays a message if the target is a type of bear.