• 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.

Make Unit move 1 step forward to what he's facing

Status
Not open for further replies.
Level 12
Joined
May 22, 2015
Messages
1,051
  • trigger
  • events
  • conditions
  • actions
    • set tempPoint1 = Position of (myUnit)
    • set tempPoint2 = (tempPoint1) offset by 50 towards (Facing angle of (myUnit))
    • Unit - Order (myUnit) to move to (tempPoint2)
    • Custom script: call RemoveLocation(udg_tempPoint1)
    • Custom script: call RemoveLocation(udg_tempPoint2)
Something like this might work. Though it orders the unit and you may not want that.
 
Level 5
Joined
Mar 6, 2015
Messages
130
why not using Unit-Move to a specific point 'r' forward with his facing angle
for finding r amount use different values to find the correct amount related to the current unit`s animation speed i don`t think its hard way to do that if you don`t get what i mean i can create a sample map for you
 
  • trigger
  • events
  • conditions
  • actions
    • set tempPoint1 = Position of (myUnit)
    • set tempPoint2 = (tempPoint1) offset by 50 towards (Facing angle of (myUnit))
    • Unit - Order (myUnit) to move to (tempPoint2)
    • Custom script: call RemoveLocation(udg_tempPoint1)
    • Custom script: call RemoveLocation(udg_tempPoint2)
Something like this might work. Though it orders the unit and you may not want that.

That's exactly what i'm looking for but i can't find that "towards".
 
Status
Not open for further replies.
Top