Power Types
This document outlines all available power types and their properties in the Aurora Framework.
Overview
Power types represent different resources used by classes in World of Warcraft. Each power type has a set of properties that can be accessed through the Unit class.
Available Power Types
Power Type | ID | Description | Classes |
---|---|---|---|
Mana | 0 | Primary resource for casters | Priest, Mage, Warlock, Druid, Shaman, Monk, Paladin |
Rage | 1 | Generated by taking/dealing damage | Warrior, Druid (Bear) |
Focus | 2 | Hunter's primary resource | Hunter |
Energy | 3 | Fast-regenerating resource | Rogue, Druid (Cat), Monk |
Combo Points | 4 | Secondary resource for finishers | Rogue, Druid (Cat) |
Runes | 5 | Death Knight's primary resource | Death Knight |
Runic Power | 6 | Generated by rune spending | Death Knight |
Soul Shards | 7 | Generated by specific abilities | Warlock |
Astral Power | 8 | Generated by spells and abilities | Druid (Balance) |
Holy Power | 9 | Generated by specific abilities | Paladin |
Alternate Power | 10 | Encounter-specific resource | Any |
Maelstrom | 11 | Generated by specific abilities | Shaman |
Chi | 12 | Generated by abilities | Monk |
Insanity | 13 | Generated by spells | Priest (Shadow) |
Arcane Charges | 16 | Generated by specific spells | Mage (Arcane) |
Fury | 17 | Generated by abilities | Demon Hunter |
Pain | 18 | Tank resource | Demon Hunter (Vengeance) |
Essence | 19 | Primary resource | Evoker |
Properties
Each power type has the following properties available:
Basic Properties
unit.<type> -- Current power value
unit.<type>max -- Maximum power value
unit.<type>pct -- Power percentage (0-100)
unit.<type>deficit -- Amount of power missing from maximum
Regeneration Properties
unit.<type>regen -- Power regeneration rate per second
unit.timeto(<type>, value) -- Time in seconds until reaching specified value
unit.<type>timetomax -- Time in seconds until reaching maximum power
Alternative Names
Some power types have alternative names for convenience:
Power Type | Alternative Names |
---|---|
Combo Points | cp , combopoints |
Astral Power | ap , astralpower , lunarpower |
Soul Shards | shards , soulshards |
Usage Examples
Basic Power Checks
local player = Aurora.UnitManager:Get("player")
-- Basic power value check
if player.mana < 1000 then
-- Low mana handling
end
-- Percentage check
if player.ragepct > 60 then
-- Use rage dump ability
end
-- Maximum value check
if player.energy == player.energymax then
-- Use energy to avoid capping
end
Resource Planning
-- Wait for resource regeneration
if player.energy < 50 and player.timeto("energy", 80) < 2 then
-- Resource will reach 80 in less than 2 seconds
return true
end
-- Check if resource is regenerating quickly
if player.energyregen > 10 then
-- Fast energy regeneration period
end
-- Resource deficit check
if player.manadeficit > 10000 then
-- Use mana regeneration cooldown
end
Secondary Resources
-- Combo point management
if player.combopoints >= 5 then
-- Use finisher
elseif player.combopoints == 0 then
-- Use builder
end
-- Holy power management
if player.holypower >= 3 then
-- Use spender
end
Best Practices
Resource Management
- Always check resource availability before casting abilities
- Consider regeneration rates for resource planning
- Use percentage checks for relative resource levels
- Monitor resource deficits for regeneration abilities
Resource Caps
Be careful not to waste resources by:
- Letting fast-regenerating resources cap (Energy, Focus)
- Using generators at maximum secondary resources (Combo Points, Holy Power)
- Ignoring resource regeneration mechanics
Notes
Power Type Access
- All power properties are accessed through the unit object
- Properties are case-sensitive
- Use alternative names where they make code more readable