Damage Detect variable.

Status
Not open for further replies.
Level 11
Joined
Dec 5, 2009
Messages
846
Hello. I want to detect damage and i thought you could first store the unit in an variable then do another trigger where you use the stored unit in the event Unit - Takes Damage but in that event it wont find the variable... Is there anyway to do this?
I want it like this:

  • Storing
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Attacking unit) Equal to Sorceress 0003 <gen>
    • Actions
      • Unit Group - Pick every unit in (Units within 1000.00 of (Position of (Attacking unit)) matching (((Matching unit) belongs to an enemy of (Owner of (Attacking unit))) Equal to True)) and do (Actions)
        • Loop - Actions
          • Set unit = (Picked unit)
          • Set unit2 = (sorceress0013)
          • Trigger - Turn on using the stored <gen>
  • using the stored
    • Events
      • Unit - unit Takes damage
    • Conditions
      • Unit2 Equal to (Damage source)
    • Actions
 
Level 9
Joined
Jul 10, 2011
Messages
562
use GDD (Gui-friendly damage detection)....with that system you can easily get the damage (or the damage dealer or the damaged unit^^)
 
Status
Not open for further replies.
Top