• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Missile laucher

Status
Not open for further replies.
Level 5
Joined
Sep 27, 2004
Messages
167
Sure thing.

When you fire the ability (which is really just a dummy ability) the editor checks the ground in a line toward the angle you fired untill it hits a wall. Then it fires a modified cluster rockets (only 1 missile) on that point, using a hidden caster. Result = A missile is fired toward the wall and kills all nearby the wall.
 
Level 5
Joined
Sep 27, 2004
Messages
167
I dunno if you understand any of this, but this is how i created the trigger.

Rocket Launcher
Events
Unit - A unit Begins casting an ability
Conditions
And - All (Conditions) are true
Conditions
(Ability being cast) Equal to Attack (rocket launcher)
(Unit-type of (Casting unit)) Equal to Agent
Actions
Custom script: local real loc_TempDir
Custom script: local location loc_TempPoint
Custom script: local location loc_TempPoint2
Set TempPoint2 = (Target point of ability being cast)
Custom script: set loc_TempPoint2 = udg_TempPoint2
Wait 0.01 game-time seconds
Custom script: set udg_TempPoint2 = loc_TempPoint2
Set TempDir = (Angle from (Position of (Casting unit)) to TempPoint2)
Set TempPoint = (Position of (Casting unit))
Set TempInteger = (Terrain cliff level at (Position of (Casting unit)))
Custom script: set loc_TempPoint = udg_TempPoint
Custom script: set loc_TempDir = udg_TempDir
Custom script: set udg_TempPoint = loc_TempPoint
Custom script: set udg_TempDir = loc_TempDir
For each (Integer A) from 1 to 1000, do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Terrain cliff level at (TempPoint offset by 25.00 towards TempDir degrees)) Less than or equal to TempInteger
Then - Actions
Set TempPoint = (TempPoint offset by 25.00 towards TempDir degrees)
Else - Actions
Custom script: set bj_forLoopAIndex = bj_forLoopAIndexEnd
Custom script: set loc_TempPoint = udg_TempPoint
Custom script: set udg_TempPoint = loc_TempPoint
Unit - Create 1 Attack Rocket Launcher Caster for (Owner of (Casting unit)) at (Position of (Casting unit)) facing (Angle from (Position of (Last created unit)) to (Target point of ability being cast)) degrees
Unit - Order (Last created unit) to Neutral Tinker - Cluster Rockets TempPoint
 
Status
Not open for further replies.
Top