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

Unit Movement - (dived to multiple directions)

Status
Not open for further replies.
Level 2
Joined
Nov 17, 2012
Messages
13
hello, I'm working on a Hero defense map with 4 bases, and I'm trying that the creeps when they reach the center of the map they dived themselves between 3 different paths once they reach the region assigned. And I tried making 4 regions on the center where before reaching to one they will suddenly take to a enemy base but for some reason they stay on the center and the other one is that I just made 1 region and make just different codes for them to move to the other bases, but they will just move to 1 base instead of the opposite 3. any ideas?

Map.png
 
Level 2
Joined
Nov 17, 2012
Messages
13
Do you want the group to split in 3 EVEN groups every time?

Or do you want each unit to split to a random path? Giving random numbers down each path?
If its possible to move them randomly there are 9 Creeps in total moving to the center

When you spawn each group, add it to a unit group variable, and when units enter the center, send them on their way depending on which unit group they are in.

I will try that thnak you
 

Dr Super Good

Spell Reviewer
Level 65
Joined
Jan 18, 2005
Messages
27,290
You could make the cross road a gathering point. Let quite a few units pool there and then use triggers to create 3 equal groups from those units which you then move one down each path. This is much more realistic than single lines of stupid units as it shows some basic intelligence. It can also cope with loss better as it will not send down groups with only 1 unit left in them down a path. It is also more fair than randomly selecting the parth gone down as you cannot get the situation where every unit goes down a single path due to how the RNG happens to roll (low chance but could happen in certain seeds).
 
Status
Not open for further replies.
Top