From 582cade8a97875b126de293481e89f4eb10c9a29 Mon Sep 17 00:00:00 2001 From: "Johnny C. Lam" Date: Fri, 12 Jul 2013 07:43:55 +0000 Subject: [PATCH] Fix ticket 254 - InFlightToTarget The InFlightToTarget script condition was not working due to an old implementation bug from the MoP merge in 5.0.0 where it was ignoring the spell ID parameter. Fix this issue by putting parentheses in the proper places and reordering for efficiency. git-svn-id: svn://svn.curseforge.net/wow/ovale/mainline/trunk@957 d5049fe3-3747-40f7-a4b5-f36d6801af5f --- OvaleCondition.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/OvaleCondition.lua b/OvaleCondition.lua index 1421717..41d53a7 100644 --- a/OvaleCondition.lua +++ b/OvaleCondition.lua @@ -1812,7 +1812,8 @@ end -- Spell(haunt) OvaleCondition.conditions.inflighttotarget = function(condition) - return TestBoolean(OvaleFuture:InFlight(condition[1] or OvaleState.currentSpellId == condition[1]), condition[2]) + local spellId = condition[1] + return TestBoolean(OvaleState.currentSpellId == spellId or OvaleFuture:InFlight(spellId), condition[2]) end --- Test if the distance from the player to the target is within the spell's range. -- 1.7.9.5