v0.13.8

UnitPowerType

functionimplementedavailable in: camelot

Returns a number corresponding to the power type (e.g., mana, rage or energy) of the specified unit.

signaturewowlua
function UnitPowerType(    unit: string,    index: number): (PowerType?, string?, number?, number?, number?)

Parameters

nametypedescription
unitstringThe unit whose power type to query.
indexnumberOptional value for classes with multiple powerTypes. *Indexing is 0-based.* If not specified, information about the first (currently active) power type will be returned. Default: 0.

Returns

#nametypedescription
1powerTypePowerType?the ID corresponding the the unit's queried power type.
2powerTypeTokenstring?also the power type:
3rgbXnumber?Alternative red component for this power type, see details. Nil for most of the standard power types.
4rgbYnumber?Alternative green component for this power type, see details. Nil for most of the standard power types.
5rgbZnumber?Alternative blue component for this power type, see details. Nil for most of the standard power types.

Blizzard's documentation says it may return nothing.

In wowlua's emulated client

implementedwowlua models the system behind it. what the statuses mean

Restrictions

sources

Signature and flags: Blizzard's API documentation (Blizzard_APIDocumentationGenerated) (Unit system, camelot 1.60.1). Description: warcraft.wiki.gg's API pages ↗, by its contributors, CC BY-SA 4.0 ↗.