Quantcast

Fix error with using Mind Blast in default priest script.

Johnny C. Lam [11-07-13 - 20:59]
Fix error with using Mind Blast in default priest script.

- Remove spurious "test" parameter to SpellInfo that shouldn't be there.

- If a condition that returns a number is used as a boolean, then boolean
  evaluation rules dictate that non-zero is true and zero is false.  Fix:

    if SpellCooldown(mind_blast) Spell(mind_blast)

  was probably intended to be:

    if SpellCooldown(mind_blast) == 0 Spell(mind_blast)

  which is simply just:

    Spell(mind_blast)

git-svn-id: svn://svn.curseforge.net/wow/ovale/mainline/trunk@1133 d5049fe3-3747-40f7-a4b5-f36d6801af5f
Filename
scripts/OvalePriest.lua
diff --git a/scripts/OvalePriest.lua b/scripts/OvalePriest.lua
index 2fdd0e7..c56b720 100644
--- a/scripts/OvalePriest.lua
+++ b/scripts/OvalePriest.lua
@@ -28,7 +28,7 @@ Define(inner_fire 588)
 Define(inner_will 73413)
   SpellAddBuff(inner_will inner_will=1)
 Define(mind_blast 8092)
-  SpellInfo(mind_blast shadoworbs=-1 cd=8 test)
+  SpellInfo(mind_blast shadoworbs=-1 cd=8)
 Define(mind_flay 15407)
   SpellInfo(mind_flay duration=3 canStopChannelling=1 )
   SpellAddTargetDebuff(mind_flay mind_flay=1)
@@ -83,7 +83,7 @@ AddIcon mastery=3 help=main
 	if TalentPoints(mindbender_talent) Spell(mindbender)
 	if ShadowOrbs() ==3 and {SpellCooldown(mind_blast) <1.5 or target.HealthPercent() <20 and SpellCooldown(shadow_word_death) <1.5 } Spell(devouring_plague)
 	if target.HealthPercent(less 20) Spell(shadow_word_death)
-	if SpellCooldown(mind_blast) Spell(mind_blast)
+	Spell(mind_blast)
 	if target.TicksRemain(devouring_plague) ==1 Spell(mind_flay_insanity)
 	Spell(mind_flay_insanity)
 	if not target.DebuffPresent(shadow_word_pain) Spell(shadow_word_pain)