creep movement and anti-return

zzyzxroad

TH.net Regular
Reaction score
1
I have use this to make the creeps follow a path.

grey left to grey corner
Events
Unit - A unit enters grey left <gen>
Conditions
(Owner of (Entering unit)) Equal to Player 12 (Brown)
Actions
Unit - Order (Entering unit) to Move To (Center of green corner <gen>)


Whats funny is 2 out of the 16 spawns didnt want to move, so I told them when a unit enters "spawn location" to move to the next point, and it worked.


1 of the spawns do not want to follow the path, and will just sit there.
1 of the spawns will go backwards to the point before (this is the same point where the other spawn stops.) Also, from the spawn that goes backwards, 3-4 out of 10 creeps will actually go to the end point.


any suggestions how to make all the creeps follow the right path, and to not make them go backwards?
 

Septimus

New Member
Reaction score
58
So, what you mean here is just to let them move forward ?

So, if you don't want such a situation to happen. You need to set it to patrol instead and lower the distance gab between those 2 region.
 

Cloud_FF

New Member
Reaction score
5
Erm I think that he means that he can't get units to move, or when they come back.

I solve this problem with 2 rects for sending and 1 for a heading. If you make the units you can't use the rec that you've made them in for a rect to send them. Place a small rect in a big one. The small is the rect where you create the units. This has one trigger. Then make a 2nd trigger and say that when a unit enters it it is ordered to move to a specific location (3rd rect). When it reaches the 3rd rect you can simply say that it must go to Rect4 and so on.

That helped? This should fix the problem with the back going and not moving. Just make sure that the 2nd rect is big enough for all the new units to fit in it, else it won't work.

P.S. I use ...order (Triggering Unit)... sine you order the unit which enters the rec, in other words the triggering unit. Dunno if there is an actual difference.
 

Builder Bob

Live free or don't
Reaction score
249
I'm struggling with a similar problem, and I think I've found a solution.

When the creeps turn back to the position they were created they are issued a move order. To prevent this move, set up a trigger looking something like this

Code:
ContinueMove
    Events
        Unit - A unit Is issued an order targeting a point
    Conditions
        (Issued order) Equal to (Order(move))
        ...additional conditions
    Actions
        Unit - Order (Triggering unit) to Attack-Move To [region of your choice]

Now, every time the creeps think about turning back, they will continue moving to the region they were going to. Of course there is the problem of knowing which region to send them to. This is where the additional conditions come in.


If you just want every creep to never return to their initial position, you can just set the gameplay constant Creeps - Guard Distance to a really high number, so they can go as far away as they like.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top