LearningCode
New Member
- Reaction score
- 24
Yea..
I was trying to make a trigger register an event for when an ability was cast.
Player casts
Trigger checks ability ID
Trigger does action
Problem is, I've got a syntax error and I don't know how to fix it =x
(Still learning)
Any help? xD
[EDIT]
Okay, figured it out.
I'm supposed to use:
Not:
I was trying to make a trigger register an event for when an ability was cast.
Player casts
Trigger checks ability ID
Trigger does action
Problem is, I've got a syntax error and I don't know how to fix it =x
(Still learning)
JASS:
function GaiaCond takes nothing returns boolean
return GetSpellAbilityId() == 039;Kchn039;
endfunction
function Trig_GaiaBladeCast_Actions takes nothing returns nothing
endfunction
//===========================================================================
function InitTrig_GaiaBladeCast takes nothing returns nothing
local trigger t = CreateTrigger( )
local integer i = 0
local player p
loop
exitwhen i==8
set p =Player(i)
call TriggerRegisterPlayerUnitEvent(t,p,EVENT_UNIT_SPELL_EFFECT,null) //This is where the error is
set i =i+1
endloop
call TriggerAddCondition(t, Condition(function GaiaCond))
call TriggerAddAction( t, function Trig_GaiaBladeCast_Actions )
endfunction
Any help? xD
[EDIT]
Okay, figured it out.
I'm supposed to use:
Not: