# Method Unit:GetCreatureType [-] [+]

Returns the Unit's creature type ID (enumerated in CreatureType.dbc).

    enum CreatureType
    {
        CREATURE_TYPE_BEAST            = 1,
        CREATURE_TYPE_DRAGONKIN        = 2,
        CREATURE_TYPE_DEMON            = 3,
        CREATURE_TYPE_ELEMENTAL        = 4,
        CREATURE_TYPE_GIANT            = 5,
        CREATURE_TYPE_UNDEAD           = 6,
        CREATURE_TYPE_HUMANOID         = 7,
        CREATURE_TYPE_CRITTER          = 8,
        CREATURE_TYPE_MECHANICAL       = 9,
        CREATURE_TYPE_NOT_SPECIFIED    = 10,
        CREATURE_TYPE_TOTEM            = 11,
        CREATURE_TYPE_NON_COMBAT_PET   = 12,     // This and below is TBC+
        CREATURE_TYPE_GAS_CLOUD        = 13
    };

## Synopsis

`creatureType = Unit:GetCreatureType()`

## Arguments

None.

## Returns

`CreatureType creatureType`
  See method description.

# Keyboard shortcuts

?
  Show this help dialog
S
  Focus the search field
⇤
  Move up in search results
⇥
  Move down in search results
⏎
  Go to active search result

# Search tricks

Prefix searches with a type followed by a colon (e.g. `fn:`) to restrict the search to a given type.

Accepted types are: `fn`, `mod`, `struct` (or `str`), `enum`, `trait`, `typedef` (or `tdef`).

Generated on
© 2010 - 2024 Eluna Lua Engine