- Joined
- Aug 8, 2010
- Messages
- 1,022
Hello! I want to ask ya a question... I am creating a spell, called Spinning Blade. What it does? - Your hero hurls a blade that will never stop and will cut everything in its path, dealing 50 dmg on first level. But there are two problems:
1st - when i clear my leak (in the 'Move Trigger'), the blade is spawned at the center of the map and doesn't move, but when i don't clear it and i leave it alone, everything works well.
2nd - when i hurl a second blade, the first one stops and instead - the second one begins to move. (hashtables make the spells MUI, right?)
Thank you very much!
1st - when i clear my leak (in the 'Move Trigger'), the blade is spawned at the center of the map and doesn't move, but when i don't clear it and i leave it alone, everything works well.
2nd - when i hurl a second blade, the first one stops and instead - the second one begins to move. (hashtables make the spells MUI, right?)
-
Cast Trigg
-
Events
- Unit - A unit Starts the effect of an ability
-
Conditions
- (Ability being cast) Equal to Spinning Blade
-
Actions
- Hashtable - Save Handle Of(Casting unit) as 1 of 1 in SBHash
- Hashtable - Save Handle Of(Target point of ability being cast) as 2 of 1 in SBHash
- Hashtable - Save Handle Of(Position of (Load 1 of 1 in SBHash)) as 2 of 2 in SBHash
- Hashtable - Save (Angle from (Load 2 of 2 in SBHash) to (Load 2 of 1 in SBHash)) as 3 of 1 in SBHash
- Unit - Create 1 Spinning Blade for (Triggering player) at ((Load 2 of 2 in SBHash) offset by 70.00 towards (Load 3 of 1 from SBHash) degrees) facing Default building facing degrees
- Hashtable - Save Handle Of(Last created unit) as 1 of 2 in SBHash
- Hashtable - Save Handle Of(Position of (Load 1 of 2 in SBHash)) as 2 of 3 in SBHash
- Set SBPoint = (Load 2 of 3 in SBHash)
- Trigger - Turn on Move Trigger <gen>
-
Events
-
Move Trigger
-
Events
- Time - Every 0.02 seconds of game time
- Conditions
-
Actions
- Set SBPoint = (SBPoint offset by 13.00 towards (Load 3 of 1 from SBHash) degrees)
- Unit - Move (Load 1 of 2 in SBHash) instantly to SBPoint
- Custom script: call RemoveLocation (udg_SBPoint)
-
Events
Thank you very much!