Quantcast

Fix TicksRemain() condition.

Johnny C. Lam [03-11-13 - 07:29]
Fix TicksRemain() condition.

git-svn-id: svn://svn.curseforge.net/wow/ovale/mainline/trunk@749 d5049fe3-3747-40f7-a4b5-f36d6801af5f
Filename
OvaleCondition.lua
diff --git a/OvaleCondition.lua b/OvaleCondition.lua
index 8557e87..1cd43ef 100644
--- a/OvaleCondition.lua
+++ b/OvaleCondition.lua
@@ -2532,13 +2532,7 @@ OvaleCondition.conditions.ticksremain = function(condition)
 	local start, ending, _, spellHasteMultiplier = GetTargetAura(condition, getTarget(condition.target))
 	local tickLength = OvaleData:GetTickLength(condition[1], spellHasteMultiplier)
 	if tickLength then
-		local remain = 1
-		local tickTime = ending
-		while tickTime - tickLength > OvaleState.currentTime do
-			remain = remain + 1
-			tickTime = tickTime - tickLength
-		end
-		return start, ending, remain, tickTime, -1/tickLength
+		return 0, nil, 1, ending, -1/tickLength
 	end
 	return nil
 end