changeset 30:d66bb6a8d8bb

Correct OnEvent with events1player
author contrebasse
date Fri, 10 Dec 2010 22:46:30 +0100
parents f14fad7938a4
children 37d2dcb3688d
files Degaine.lua
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/Degaine.lua	Fri Dec 10 22:42:46 2010 +0100
+++ b/Degaine.lua	Fri Dec 10 22:46:30 2010 +0100
@@ -114,7 +114,7 @@
 	UNIT_SPELLCAST_INTERRUPTED = true,
 	UNIT_SPELLCAST_SUCCEEDED = true,
 }
-local SpellWhiteList = {
+local SpellWhiteList = { -- Spells that do steath weapons (works with events1player)
 	[8690] = true, -- Heartstone
 	[818] = true, -- Basic Campfire
 }
@@ -251,7 +251,7 @@
 		end
 	elseif events1player[event] then
 		if arg1=="player" then
-			if arg5==nil or SpellWhiteList[arg5] then -- arg5 is SpellID
+			if arg5 and SpellWhiteList[arg5] then -- arg5 is SpellID
 				start()
 			end
 		end