Okay, I'm attempting to make a spell that I'm calling "Airflip Combo" (Probably need a better name) Which works like this:
The Dummy spell is based off Polymorph, and makes them into flying sheep (which should grant flight right?)
My problem is the unit will not increase his height and is being sent to far away, heres my Triggers so far:
- A Cord Connecting the two units appear (I'm not including this part in my code as it is easy)
The "Flipe" (One being flipped) basiccaly does a jump over the unit and to the otherside of him.
The "Flipe" Hits the ground, reciving damage.
The Dummy spell is based off Polymorph, and makes them into flying sheep (which should grant flight right?)
My problem is the unit will not increase his height and is being sent to far away, heres my Triggers so far:
Code:
AirflipComboActiv
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Airflip Combo
Actions
Set Fliper = (Casting unit)
Set flipe = (Target unit of ability being cast)
Wait 0.01 seconds
Set Fliptimer = 0
Trigger - Turn on AirflipComboUP <gen>
Code:
AirflipComboUP
Events
Time - Every 0.01 seconds of game time
Conditions
Actions
Unit - Move flipe instantly to ((Position of Fliper) offset by ((X of (Position of flipe)) - ((X of (Position of Fliper)) - 4.00)) towards (Angle from (Position of flipe) to (Position of Fliper)) degrees)
Animation - Change flipe flying height to ((Current flying height of flipe) + 3.00) at 3.00
Set Fliptimer = (Fliptimer + 1)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
Fliptimer Equal to 117
Then - Actions
Unit - Unpause Fliper
Unit - Unpause flipe
Trigger - Turn on AirflipComboDWN <gen>
Set Fliptimer = 0
Trigger - Turn off (This trigger)
Else - Actions
Do nothing
Code:
AirflipComboDWN
Events
Time - Every 0.01 seconds of game time
Conditions
Actions
Unit - Move flipe instantly to ((Position of flipe) offset by ((X of (Position of Fliper)) - ((X of (Position of flipe)) - 6.00)) towards (Angle from (Position of Fliper) to (Position of flipe)) degrees)
Animation - Change flipe flying height to ((Current flying height of flipe) - 3.00) at -3.00
Set Fliptimer = (Fliptimer + 1)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
Fliptimer Equal to 117
Then - Actions
Unit - Create 1 Dummy for (Owner of Fliper) at (Position of flipe) facing (Position of flipe)
Unit - Add a 1.50 second Generic expiration timer to (Last created unit)
Unit - Add Warstomp (Airflip) to (Last created unit)
Unit - Add Purge to (Last created unit)
Unit - Order (Last created unit) to Orc Shaman - Purge flipe
Unit - Order (Last created unit) to Orc Tauren Chieftain - War Stomp
Set Fliptimer = 0
Trigger - Turn off (This trigger)
Else - Actions
Do nothing