I'm making a defense map where units walk down a simple lane and the player needs to build a maze for the units to go through. I remember some maps where the units would attack your buildings if their path was blocked. How is this done? Currently if the path is blocked the units will get stuck.
My Defense uses disabled bunkers, could this be the reason why the offensive units do not attack?
Are there any other ways of preventing walling off completely? The only other method I can think of is adding terrain on the sides that is unbuildable.
Also, even if the player hasn't walled off, but simply built a small cavern to trap the attackers, the units often times get stuck and don't back out to go around the maze. I don't remember other similar maps (Like Defense F) having this issue. Could it be a problem with the number of units spawning, or the direction they are moving, size of the lane, or the trigger ordering the move command? Or I may just be out of luck cause i'm mostly only seeing this issue with dumber units like the dragoon and siege tank.
I do stuff and thingies... Try widening and reducing the number of small nooks and crannies to correct the problem.
Disabled bunkers are cloaked. Thus, the enemy units might not see them and therefore only flee when being attacked. So, try sharing vision.
Ah yes, I think that was it. Totally slipped my mind. Thanks!
None.
We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch
units would attack your buildings if their path was blocked. How is this done?
You order the units to move, so they normally don't attack. When their path is blocked they briefly try to find a way and when they determine there is no path to their target they simply stop, cancelling their move order. Then the normal idle unit ai kicks in and makes them stand there and attack their surroundings.