• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Solved] Cant solve :(

Status
Not open for further replies.
Level 10
Joined
May 28, 2011
Messages
455
Im making an abilities from item illusion.
I need the caster, the target abilities being cast, and the illusion summoned.
How can i detect them in single trigger instead of two trigger with event - a unit starts the of an ability and event - a unit spawns a summoned unit respectively?
im GUI user.
 
Level 26
Joined
Aug 18, 2009
Messages
4,097
  • Events
    • Map initialization
  • Conditions
  • Actions
    • Hashtable - Create a hashtable
    • Set HashTable = (Last created hashtable)
  • Events
  • Conditions
  • Actions
    • //Set Illusion and Target
    • Custom script: set udg_i = GetHandleId(udg_Illusion)
    • Hashtable - Save Handle OfTarget as 0 of i in HashTable
    • Trigger - Add to Damage <gen> the event (Unit - Illusion takes damage)
  • Damage
    • Events
    • Conditions
    • Actions
      • Set Illusion = (Triggering unit)
      • Custom script: set udg_i = GetHandleId(udg_Illusion)
      • Set Target = (Load 0 of i in HashTable)
      • Unit - Cause (Damage source) to damage Target...
Variables:
HashTable --> Hashtable
i --> Integer
Illusion --> Unit
Target --> Unit
 
Level 9
Joined
Apr 26, 2011
Messages
403
  • Events
    • Unit is attacked
  • Conditions
    • (attacking unit) is Illusion_Caster
  • Actions
    • order (attacking unit) cast Juggnaunt - Mirror Image // depend on which skill you copy from
another way :

  • Events
    • Unit is attacked
  • Conditions
    • (attacking unit) is Illusion_Caster
  • Actions
    • if (mana of (attacking unit) is full)
      • create 1 (illusion) for owner of (attacking unit) blah blah
 
Status
Not open for further replies.
Top