Atacked by ability?

kla0005

New Member
Reaction score
3
Hi Guys,

I wanted to make a explode ability. Such ass'.. My Hero casts' a Chain Lightning, and then an trigger registryes that "This unit was hitten by the Chain Lightning, do this!".. But, how do I make an event that can registrery that?
 

inevit4ble

Well-Known Member
Reaction score
38
Trigger:
  • Untitled Trigger 002
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Chain Lightning
    • Actions
      • Set MyUnit1 = (Casting unit)
      • Set MyUnit2 = (Target unit of ability being cast)
      • Unit - Cause MyUnit1 to damage MyUnit2, dealing (x) damage of attack type Spells and damage type Normal
      • Set MyUnit1 = No unit
      • Set MyUnit2 = No unit
 

inevit4ble

Well-Known Member
Reaction score
38
Trigger:
  • Untitled Trigger 002
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Chain Lightning
    • Actions
      • Set MyUnit1 = (Casting unit)
      • Set MyUnit2 = (Target unit of ability being cast)
      • Unit - Cause MyUnit1 to damage MyUnit2, dealing (x) damage of attack type Spells and damage type Normal
      • Set MyUnit1 = No unit
      • Set MyUnit2 = No unit
 

TomTTT

New Member
Reaction score
44
It's not really necessery to put the
Trigger:
  • Set MyUnit1/2= No unit

Since it's GUI.
And I think what kla0005 means is how to detect all units that were hit. In order to do that you need to trigger the spell.
You can make a dull ability, which will then trigger a trigger such as this: (handwritten...)
Trigger:
  • Set Unit[1] = (Triggering unit)
    • Set Unit[2] = (Target unit of ability being cast)
    • Set Point[1] = (Position of Unit[1])
    • Set Point[2] = (Position of Unit[2])
    • Lightning - Create a Chain Lightning - Primary lightning effect from source Point[1] to target Point[2]
    • Set Lightning[1] = (Last created lightning effect)
    • Unit - Cause (Triggering unit) to damage Unit[2], dealing X damage of attack type Chaos and damage type Normal
    • Set Group[1] = (Units within 250.00 of Point[2] matching (((Owner of (Matching unit)) is an enemy of (Owner of (Triggering unit))) Equal to True) and ((Matching unit) is Not equal to Unit[2])
    • Set Unit[3] = (Random unit from Group[1])
    • Set Point[3] = (Position of Unit[3])
    • Lightning - Create a Chain Lightning - Primary lightning effect from source Point[2] to target Point[3]
    • Set Lightning[2] = (Last created lightning effect)
    • Unit - Cause (Triggering unit) to damage Unit[3], dealing X damage of attack type Chaos and damage type Normal

You can continue this on and on. :D
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top