Tree plow

Azathrael

New Member
Reaction score
0
Also, will the loop (aka tree plow) end when the ability ends? Or do I need to add additional stuff for that too?
 

canons200

New Member
Reaction score
50
under the Destructible, just scroll down, you will see this
Trigger:
  • Destructible - Pick every destructible within 256.00 of (Center of (Playable map area)) and do (Actions)
    • Loop - Actions

change those value to the above trigger

the loop will auto end when every destructible within the range is picked.

just do as above, it will work fine
 

Azathrael

New Member
Reaction score
0
Thank you for all your help guys. I messed around with the code blindly and got it to work (pure miracle I'd say)

JASS:
function Trig_BlazeFury_Conditions takes nothing returns boolean
    return GetSpellAbilityId() == 'A00J'
endfunction

function killtree takes nothing returns nothing
    call KillDestructable (GetEnumDestructable())    
endfunction

function Trig_BlazeFury_Actions takes nothing returns nothing
    local integer x = 0
    local integer y = 4  //How long tha ability Lasts
    local real range = 225 //The killing radius
    loop
	call EnumDestructablesInCircleBJ( range,GetUnitLoc(GetTriggerUnit()),function killtree)
        call TriggerSleepAction(1)
        set x = x + 1
        exitwhen(x == (y))
    endloop
endfunction

function InitTrig_BlazeFury takes nothing returns nothing
    local trigger t = CreateTrigger()
    call TriggerRegisterAnyUnitEventBJ (t, EVENT_PLAYER_UNIT_SPELL_CAST)
    call TriggerAddCondition (t, Condition( function Trig_BlazeFury_Conditions))
    call TriggerAddAction (t, function Trig_BlazeFury_Actions)
endfunction
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top