HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Need help with unit following another unit

06-09-2004, 08:30 PM#1
anctan
Hi.
How can I make a unit follow another unit by going the same distance in the same direction as the unit to be followed?
06-09-2004, 10:57 PM#2
johnfn
I dont know if you mean

1) Follow behind
or
2) Follow in their face

If, 2), then just order the unit to the position of the other unit. Otherwise, you need to set a variable every 2 seconds to the position of the unit, and then wait till right before you set it and order it to the old position.

If you're confused, just ask, I'll try to explain.
06-10-2004, 03:55 PM#3
anctan
Yes, I think I need an explanation on this.
06-10-2004, 08:07 PM#4
johnfn
You will need a trigger like this.


Periodic event - Every 2 seconds

Order Follower unit to (Old position)
set Old Position to position of [Unit being followed]

Seems easy enough. Just remeber to set the position of the position in the first place.