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

How to stop units from walking in a straight line when moving to a point

Status
Not open for further replies.
Level 5
Joined
Apr 13, 2008
Messages
184
I have this hero defence map and when i spawn creeps and move them, they end up colliding with one another and walking in a straight line. How do i get them to move in a formation/cluster instead? I've tried moving them to a midway point and waiting for a few units before issuing another attack-move order but they end up moving back to their spawn point, which was pretty wierd.

Dropbox - Rec 024.mp4 - Simplify your life
The dropbox link is a video showing the movement of the spawn
 
Level 12
Joined
Nov 3, 2013
Messages
989
To prevent the units from moving back to their spawn point, use 'ai - remove guard position'.


As for the formation movement, to get the units to not line up in a row you'd have to not make them all move towards the exact same position, and you'd probably want to spawn them next to each other instead of on the same location as well... (So they don't end up running into/colliding with each other.)


Actually I remembered seeing a formation map before and found it again by just googling

But checking the map, the units have no collision so that obviously makes things a whole lot easier.
 
You get a formation by ordering the units with the unit group actions instead of ordering them unit specific, Then they work as group but that group order actions are limited to 12 units in one group (selection limit). You might have to save the units group when there are multiple checkpoints and think about how to order them again after they arrived at a checkpoint.
 
Level 5
Joined
Apr 13, 2008
Messages
184
You get a formation by ordering the units with the unit group actions instead of ordering them unit specific, Then they work as group but that group order actions are limited to 12 units in one group (selection limit). You might have to save the units group when there are multiple checkpoints and think about how to order them again after they arrived at a checkpoint.

Yeah it works better now, they still go in a line when they pass through corners though. Unfortunately there are quite a few corners
 
Level 5
Joined
Apr 13, 2008
Messages
184
To prevent the units from moving back to their spawn point, use 'ai - remove guard position'.


As for the formation movement, to get the units to not line up in a row you'd have to not make them all move towards the exact same position, and you'd probably want to spawn them next to each other instead of on the same location as well... (So they don't end up running into/colliding with each other.)


Actually I remembered seeing a formation map before and found it again by just googling

But checking the map, the units have no collision so that obviously makes things a whole lot easier.
Yeah i saw this video before but it needs a unit leader, a little bit more troublesome to implement but its cool though.
 
Status
Not open for further replies.
Top