- Joined
- Sep 30, 2012
- Messages
- 205
Hey I wanted to create a custom spell, which works kinda like the "Staff of Preservation" but could target enemy units as well, so they get ported back to their base (and not yours)
However i tried it with create "staff of preservation" and give it to dummy unit, and use it on the target unit of ability being cast.
Use item in slot one, or use item of type "Staff of Preservation" nor use dummy items seemed to work.
So now i tried with make item ability a unit ability and use it on the unit...
However thats not working either... but i'm unsure with the order id thingy..
Any thoughts? i would appreciate it! cheers
So yeah the triggers still contain the left overs of the "create item and give it to unit and all" and the wait also didn't helped... sometimes a wait 0 does the trick, not here... i know waits are bad..
wuups caption should have read spellorderid?!?
However i tried it with create "staff of preservation" and give it to dummy unit, and use it on the target unit of ability being cast.
Use item in slot one, or use item of type "Staff of Preservation" nor use dummy items seemed to work.
So now i tried with make item ability a unit ability and use it on the unit...
However thats not working either... but i'm unsure with the order id thingy..
Any thoughts? i would appreciate it! cheers
So yeah the triggers still contain the left overs of the "create item and give it to unit and all" and the wait also didn't helped... sometimes a wait 0 does the trick, not here... i know waits are bad..
wuups caption should have read spellorderid?!?
-
Untitled Trigger 001
-
Events
- Unit - A unit Starts the effect of an ability
- Conditions
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Ability being cast) Equal to Chain Lightning *Recoil
-
Then - Actions
- Set TempUnit = (Target unit of ability being cast)
- Set TempPoint = (Position of TempUnit)
- Set tempPlayer = (Owner of TempUnit)
- Unit - Create 1 Templar for tempPlayer at TempPoint facing Default building facing degrees
- Set TempUnit2 = (Last created unit)
- Item - Create Staff of Preservation at TempPoint
- Set DummyItem = (Last created item)
- Hero - Give DummyItem to TempUnit2
- Unit - Add Staff of Preservation to TempUnit2
- Wait 1.00 seconds
- Custom script: call IssueTargetOrderById(udg_TempUnit2,852568,udg_TempUnit)
- Set TempUnit = No unit
- Custom script: set udg_tempPlayer = null
- Custom script: call RemoveLocation( udg_TempPoint )
- Set DummyItem = No item
- Unit - Add a 2.00 second Generic expiration timer to TempUnit2
- Set TempUnit2 = No unit
- Else - Actions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
Events