Faceless Void's Backtrack

NWR

New Member
Reaction score
0
How do you trigger FV's Backtrack so that it blocks both physical and spell damage? The same thing with Spectre's Dispersion cept it damages enemies around it. Could someone just provide a little explanation on how you would do this? All I know is it takes damage type into and runs a trigger
 

kingkingyyk3

Visitor (Welcome to the Jungle, Baby!)
Reaction score
216
Use damage system.
Use the system to deal all spell's damage. The rest damage are attack damage.
 

Jesus4Lyf

Good Idea™
Reaction score
397
JASS:
scope Backtrack initializer OnInit
    globals
        private constant integer ABIL='A00X'
    endglobals
    private function DodgeChance takes integer level returns real
        return 0.1*level
    endfunction
    private function OnDamage takes nothing returns boolean
        local integer level=GetUnitAbilityLevel(GetTriggerUnit(),ABIL)
        if level>0 then
            if GetRandomReal(0,1)<=DodgeChance(level) then
                call Damage_BlockAll()
            endif
        endif
        return false
    endfunction
    private function OnInit takes nothing returns nothing
        local trigger t=CreateTrigger()
        call TriggerAddCondition(t,Filter(function OnDamage))
        call Damage_RegisterEvent(t)
    endfunction
endscope

Uses Damage.
 
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