Need Help

zepho

New Member
Reaction score
0
Can you find out what's wrong with my trigger ? I'm using Vexorian's CS. All this trigger does when I cast the spell is show a message "cast". The other codes won't work. Please help. Thanks.

JASS:
function Trig_SpellSurge_Conditions takes nothing returns boolean
    return  GetSpellAbilityId() == 'A00C' 
endfunction

function Trig_SpellSurge_Actions takes nothing returns nothing

 local location loc = GetSpellTargetLoc()
 local unit     u   = GetTriggerUnit()
 local integer dopt
    set dopt = DamageTypes(ATTACK_TYPE_HERO,DAMAGE_TYPE_MAGIC) + DontDamageSelf() 
 call AddAreaDamagerForUnitLoc(u, "Abilities\\Spells\\Demon\\DarkPortal\\DarkPortalTarget.mdl", "Abilities\\Spells\\NightElf\\FaerieDragonInvis\\FaerieDragon_Invis.mdl", "overhead", loc, 200. , 0.02, 0.02, 325., false, dopt)
 call PolledWait(0.5)
 call RemoveLocation(loc)
 call BJDebugMsg("cast")
 set loc=null
 set u=null
endfunction

function InitTrig_SpellSurge takes nothing returns nothing
    local trigger gg_trg_SpellSurge = CreateTrigger(  )
    local integer int = 0
    loop
        exitwhen int == bj_MAX_PLAYERS
        call TriggerRegisterPlayerUnitEvent(gg_trg_SpellSurge,Player(int),EVENT_PLAYER_UNIT_SPELL_EFFECT,null)
        set int = int + 1
    endloop
    call TriggerAddCondition( gg_trg_SpellSurge, Condition( function Trig_SpellSurge_Conditions ) )
    call TriggerAddAction( gg_trg_SpellSurge, function Trig_SpellSurge_Actions )
    set gg_trg_SpellSurge = null
endfunction
 

NoobImbaPro

You can change this now in User CP.
Reaction score
60
to define a problem you must first say what's the problem, we are not guru's here.
that dopt sounds somehow troublesome
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top