Record the correct number of CPs used in a spellcast.
Johnny C. Lam [05-03-14 - 00:25]
Record the correct number of CPs used in a spellcast.
The sanity-check condition wasn't right because it assumed that you must
have at least one CP to cast any finisher; instead, it should honor any
"min_combo" paraemter listed in SpellInfo().
git-svn-id: svn://svn.curseforge.net/wow/ovale/mainline/trunk@1356 d5049fe3-3747-40f7-a4b5-f36d6801af5f
diff --git a/OvaleFuture.lua b/OvaleFuture.lua
index d66579c..4a259d8 100644
--- a/OvaleFuture.lua
+++ b/OvaleFuture.lua
@@ -1,7 +1,7 @@
--[[--------------------------------------------------------------------
Ovale Spell Priority
Copyright (C) 2012, 2013 Sidoine
- Copyright (C) 2012, 2013 Johnny C. Lam
+ Copyright (C) 2012, 2013, 2014 Johnny C. Lam
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License in the LICENSE
@@ -177,7 +177,8 @@ local function AddSpellToQueue(spellId, lineId, startTime, endTime, channeled, a
spellcast.combo = MAX_COMBO_POINTS
end
end
- if OvaleComboPoints.combo > 0 then
+ local min_combo = si.min_combo or si.mincombo or 1
+ if OvaleComboPoints.combo >= min_combo then
spellcast.combo = OvaleComboPoints.combo
end
end