• 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.

Need help for my spell of last created unit.

Status
Not open for further replies.
Level 2
Joined
Jul 15, 2016
Messages
26
Hey there i have a problem here, it is i have many spells requires

to( create 1 dummy),
(add<spell> to last create unit),
(set level of<spell> for last created unit to level of blabla bla) and
(order last create unit to bla bla bla)


i have many kind of spell using this kind of trigger.

the problem is to many of it cause some of my spell don't work correctly even my triggers are right.
Can anyone help me pls?
 
Level 13
Joined
Jul 15, 2007
Messages
763
Do what PrinceYaser says, do variables, or better yet, use a master dummy if appropiate.

Chances are you have other spells/systems in your map that are reactive when you create your dummy so that it is no longer the 'last created unit' (because your other spells/triggers are creating units inbetween the time you create your dummy and order it to cast).
 
Level 2
Joined
Jul 15, 2016
Messages
26
PrinceYaser can you show me an example of the variable for storing the last created unit? i am not sure should set it as unit or unit type?
 
Last edited:
Status
Not open for further replies.
Top