From 49cfd16fe2624e18eae4d1e69d60335c3abf8ecc Mon Sep 17 00:00:00 2001 From: "Johnny C. Lam" Date: Fri, 6 Jun 2014 21:12:46 +0000 Subject: [PATCH] Add RunicPowerCost(spellId) to get runic power needed to cast a spell. git-svn-id: svn://svn.curseforge.net/wow/ovale/mainline/trunk@1520 d5049fe3-3747-40f7-a4b5-f36d6801af5f --- conditions/PowerCost.lua | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/conditions/PowerCost.lua b/conditions/PowerCost.lua index b7f113a..ea38e41 100644 --- a/conditions/PowerCost.lua +++ b/conditions/PowerCost.lua @@ -77,8 +77,22 @@ do return PowerCost("rage", condition) end + --- Get the amount of runic power required to cast the given spell. + -- @name RunicPowerCost + -- @paramsig number or boolean + -- @param id The spell ID. + -- @param operator Optional. Comparison operator: less, atMost, equal, atLeast, more. + -- @param number Optional. The number to compare against. + -- @return The amount of runic power. + -- @return A boolean value for the result of the comparison. + + local function RunicPowerCost(condition) + return PowerCost("runicpower", condition) + end + OvaleCondition:RegisterCondition("energycost", true, EnergyCost) OvaleCondition:RegisterCondition("focuscost", true, FocusCost) OvaleCondition:RegisterCondition("manacost", true, ManaCost) OvaleCondition:RegisterCondition("ragecost", true, RageCost) -end \ No newline at end of file + OvaleCondition:RegisterCondition("runicpowercost", true, RunicPowerCost) +end -- 1.7.9.5