Muert39620@legacy41559547 (talk | contribs) No edit summary |
({{wowapi}}, format) |
||
Line 1: | Line 1: | ||
+ | {{wowapi}} __NOTOC__ |
||
− | <center>'''UnitCreatureFamily''' ''-Documentation by [[User:Boro|Boro]]-''</center> |
||
− | |||
Returns the creature family of the specified unit (e.g., "Crab" or "Wolf"), or nil if the unit does not have a creature family (e.g. because it is not a creature). |
Returns the creature family of the specified unit (e.g., "Crab" or "Wolf"), or nil if the unit does not have a creature family (e.g. because it is not a creature). |
||
⚫ | |||
+ | ==Parameters== |
||
⚫ | |||
⚫ | |||
+ | :;unit : [[UnitId]] - unit you wish to query. |
||
⚫ | |||
⚫ | |||
⚫ | |||
− | ---- |
||
⚫ | |||
⚫ | |||
⚫ | |||
− | |||
⚫ | |||
− | :(String unit) |
||
⚫ | |||
− | |||
− | :;unit : the unit name (e.g., "target", "mouseover") |
||
− | |||
− | ---- |
||
⚫ | |||
− | |||
− | :creatureFamily |
||
⚫ | |||
− | |||
− | ---- |
||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
− | |||
⚫ | |||
If the target is a bear, then you jump. |
If the target is a bear, then you jump. |
||
− | |||
− | ---- |
||
− | ;''Description'' |
||
− | |||
− | : Returns the creature family of the specified unit (e.g., "Crab" or "Wolf"), or nil if the unit does not have a creature family (e.g. because it is not a creature). |
||
− | |||
− | ---- |
||
− | {{WoW API}} |
Revision as of 19:15, 23 December 2006
Automated updating of API pages at this location, to reflect patch changes, has ceased from 10.1.7 onwards. |
Returns the creature family of the specified unit (e.g., "Crab" or "Wolf"), or nil if the unit does not have a creature family (e.g. because it is not a creature).
creatureFamily = UnitCreatureFamily(unit);
Parameters
Arguments
- unit
- UnitId - unit you wish to query.
Returns
- creatureFamily
- String - name of the creature family (e.g., "Crab" or "Wolf")
Example
if ( UnitCreatureFamily("target") == "Bear" ) then Jump(); -- jump for joy because you found Pooh end
Result
If the target is a bear, then you jump.