[Usable by GUI/Jass/vJass]
This is a triggered movement system for units or a Projectile system. It is used to fire projectiles, make charge abilities, skillshot abilities and shockwaves, etc. and without effort, just using the syntax. The full explanation is inside the map. Please read all the Trigger Comments.
This system uses TriggerHappy's Timed Life for Effect system to automatically remove the explosion SFX.
- destination point, speed, minimum range needed between the projectile and the destination to finish.
- arcing in sin graph with maximum height.
- collision size and damage.
- supports 1 target only mode. Basically the projectile will stop when it collides a target
- A trigger that can be activated when a unit is hit in 1 target only mode.
- Explosion on end, which is basically an AoE damage when it reaches the destination.
- Area of Effect, damage, SFX for the explosion
- A trigger that is activated when the explosion occurs
- Whether the projectile is automatically removed when it ends.
You can also just use the motion of the system and manually assign triggers for the unit. Example of this is activating a trigger whenever a unit is touched by the projectile, but without ending the movement. (Currently the available type in this system is to activate a trigger for collision only when 1 target only mode is on)
Note: This system is designed for fixed points, not for moving locations/moving units.
Some Usages for example:
Usage Syntax [For GUI, explanation is inside the map]:
- A custom shockwave that deals attribute of a hero as damage.
- A spear ability that stops at the first target.
- A unit charge ability to a specific location
- A rocket that explodes at the target location.
call UnitMovingPointInit( unit u, real x, real y, real speed, real CheckRange, boolean FirstTarget, real DamageDuringPath, real CollisionSize, trigger CollisionTrig, boolean ExplodeInEnd, real ExplodeDamage, real ExplodeAoE, trigger EndingTrig, string ExplodeSFX, boolean Remove, boolean End)
How to Import:
Just copy Unit Movement System and Timed Life for Effects to your map.
Code is in Preview Triggers
Update 1: Index will be reset if all instances are over (Only if the UnitMovingPointU for each instance = null). Did some small changes for test map to look better.
Update 2: Added a library initializer. So now the system trigger can be renamed without issues.
Update 3: Actually added that initializer, sorry.
Update 4: Added the option to make the projectile arc using Sin graph.
In the Future: Special Effect projectiles support and homing projectiles.
keywords: projectile, system, trigger, movement, motion, unit, GUI, jass, skillshot