- Joined
- Dec 31, 2005
- Messages
- 712
OK!
I made an ability with triggers thar, when the hero casts it, appears two invisible units that cast the same ability, the first one +40 degrees and the other -40 degrees. But... the units don't cast it to the right point and I don't know why.
The trigger is like this:
Events:
A Unit Begins Casting An Ability
Conditions:
(Ability Being Cast) Equal To (Impact)
Actions:
Set IMCaster = (Casting Unit)
Set IMPoint[1] = (Position of IMCaster) Offset By 100 towards ((Facing of IMCaster) + 40) Degrees
Set IMPoint[2] = (Position of IMCaster) Offset By 100 towards ((Facing of IMCaster) - 40) Degrees
Create 1 Impact-Caster for (Owner of (Casting Unit)) at (Position of (Casting Unit)) Facing (IMPoint[1])
Set IMUnit[1] = (Last Created Unit]
Set Level of ImpactUnit for (IMUnit[1]) = Level of Impact for (IMCaster)
Order (IMUnit[1]) to Tauren Chieftain - Shockwave IMPoint[1]
Create 1 Impact-Caster for (Owner of (Casting Unit)) at (Position of (Casting Unit)) Facing (IMPoint[2])
Set IMUnit[2] = (Last Created Unit]
Set Level of ImpactUnit for (IMUnit[2]) = Level of Impact for (IMCaster)
Order (IMUnit[2]) to Tauren Chieftain - Shockwave IMPoint[2]
Already thanks
Marcelo
I made an ability with triggers thar, when the hero casts it, appears two invisible units that cast the same ability, the first one +40 degrees and the other -40 degrees. But... the units don't cast it to the right point and I don't know why.
The trigger is like this:
Events:
A Unit Begins Casting An Ability
Conditions:
(Ability Being Cast) Equal To (Impact)
Actions:
Set IMCaster = (Casting Unit)
Set IMPoint[1] = (Position of IMCaster) Offset By 100 towards ((Facing of IMCaster) + 40) Degrees
Set IMPoint[2] = (Position of IMCaster) Offset By 100 towards ((Facing of IMCaster) - 40) Degrees
Create 1 Impact-Caster for (Owner of (Casting Unit)) at (Position of (Casting Unit)) Facing (IMPoint[1])
Set IMUnit[1] = (Last Created Unit]
Set Level of ImpactUnit for (IMUnit[1]) = Level of Impact for (IMCaster)
Order (IMUnit[1]) to Tauren Chieftain - Shockwave IMPoint[1]
Create 1 Impact-Caster for (Owner of (Casting Unit)) at (Position of (Casting Unit)) Facing (IMPoint[2])
Set IMUnit[2] = (Last Created Unit]
Set Level of ImpactUnit for (IMUnit[2]) = Level of Impact for (IMCaster)
Order (IMUnit[2]) to Tauren Chieftain - Shockwave IMPoint[2]
Already thanks
Marcelo