I'm working on a turret defense type map, and I'm trying to figure out how to prevent players from creating a wall of buildings to block the ground units. Preferably, if a player walls, the ground units will attack that player's buildings (though attacking all buildings would be fine) until they are no longer blocked.
I have looked through this forum, so here's what I've tried already:
1. Just use the move command, when the path is blocked the units will stop and if they are hostile, they will attack. I tried this, but the ground units just kept running back and forth when they hit the wall. They never stopped and never attacked, except for tanks which seem to just attack when they stand still for a moment.
2. Use the patrol/attack command. In both cases, the ground units attack even when there is an opening, though they will walk through the opening occasionally when I use patrol.
Also, I would like to avoid using tons of locations. My track is too big to do that, and actually detecting a wall with static locations seems unreliable.
I have seen a few maps that did this successfully, so I know it is possible, but they were all protected, so I don't know how.
Thank you for your help.
Update:
I finally discovered that if I place the wall close to the starting position, the enemies will start attacking, but it it is farther away, they will not. If fact, if I place one close wall and one a bit farther, the first will be attacked, but the second will be left alone. I guess this means that the move command *should* do what I want, but Starcraft often has a hard time discovering that the path is indeed blocked.
Thank you for the suggestions so far, and especially for the link from Urmom(U) which helped me get this far, but my problem is still not completely solved.
it seems like you're preserving the move trigger, if so, don't
Send a specific unit first (Civilian or anyunit) and have the trigger set to when this unit is at the end of the path it starts the level.
People could just open the wall up for a split second and then wall again...
QUOTE(Zeratul_101 @ Sep 21 2006, 10:52 AM)
it seems like you're preserving the move trigger, if so, don't
[right][snapback]565377[/snapback][/right]
I am preserving the trigger, but it only affects a small location at the beginning of the path, and the units aren't walking back that far.
Well are you using a trigger that moves them constantly, with preserve trigger? like:
C:
Whatever...
A:
Order(All,anyunit,move,locA,LocB)
PreserveTrigger();
how bout putting in some sort of wait action, or timer or something, so that they move to location, and if they are blocked they will have time to stop and attack, and the trigger'll fire again, making them stop attacking and move again, and if its still blocked, they will attack again, so:
C:
Whatever...
A:
Order(all,anyunit,move,LocA,LocB);
Wait(10000); [or use a deathcount timer or something, and any timer you want, however long you want them to attack for until they start moving again]
PreserveTrigger();
does that make sense?
ADDITION:
and make sure LocB spans the whole length of the computers movement to LocA so that they dont stop halfway and dont move again
QUOTE(Urmom(U) @ Sep 21 2006, 03:35 PM)
Here I did a search just for you. This is what I came up with:
http://www.staredit.net/index.php?showtopic=10791&hl=[right][snapback]565445[/snapback][/right]
An update on the situation: with an example map in this thread, I see that the using the move command will indeed make the units stop and attack, and I was even able to create my own example map in which the units do this. But, in the map I am making, they refuse to attack. They are enemies and will attack when the patrol or attack commands are used, but it is as if the computer does not detect that the path is blocked. I'm still trying to figure out why this is.
alliance status, invincible units, priority attacking(melee units blocking the enemies from getting close enough to attack more danerous ranged units)?
i think what he means by stoping from walling is like tree d, when the player blocks path, the units attack, but dont attack when they dont block the path.
what are you talking about? we all already know what he means, its a pretty common phenonemum
well no body is giveing him a straight awnser and makes it look like you dont know what he means
QUOTE(Lord-Omega @ Sep 22 2006, 12:14 PM)
well no body is giveing him a straight awnser and makes it look like you dont know what he means
[right][snapback]565925[/snapback][/right]
The first couple answers, including the referenced post, are exactly what I am talking about, but they don't really solve the problem. Also, there is no problem with "priority attacking" in my test, but that does still sound like it could be a problem in general.
lol, its a melee exploit. anyhow, you might want to post your map so people can have a detailed look into your triggers. personally, i'm not gonna do that cause i'm all 'test mapped' out. its all Jammed's fault
.
You could do terrain location
Defenses are my specialty
ok have one location at the start, always ordering them to move to the end. Make the computer ALLIED to the others and then hey wil ltry to go through, then when they cant get through they'll make the path.
Ok...why are we reviving several week old threads again?
Reported to be locked, you can delete this post too if you want.
Oh sorry guys, thought the guy would've said something if he needed more help.
QUOTE(sharf @ Oct 9 2006, 04:52 PM)
Defenses are my specialty
ok have one location at the start, always ordering them to move to the end. Make the computer ALLIED to the others and then hey wil ltry to go through, then when they cant get through they'll make the path.
[right][snapback]573873[/snapback][/right]
If the computer is allied to the players, then the computer doesn't attack them, so no buildings get destroyed and no path is made. Is there something I am missing?
ADDITION:
QUOTE(Urmom(U) @ Oct 9 2006, 06:28 PM)
Ok...why are we reviving several week old threads again?
Reported to be locked, you can delete this post too if you want.
[right][snapback]573920[/snapback][/right]
My problem was never solved, so if there are any new ideas, I would be happy to hear them. Please allow people to help if they come across this thread and feel like it.
if your on us east i can help you live il lgo on my map RIGHT NOW and il lcheck my triggers
ADDITION:
my tirrigers are and work... always set defenders to ally(teh computers) preserve trigger and then always order units at 1 move to 2 2 - 1 3 - 4 4 - 3 5 - 6 6 - 5 or what ever urs are. they will move, and no matter what if they are blocked the yattack trust me it works.
QUOTE(sharf @ Oct 9 2006, 06:08 PM)
if your on us east i can help you live il lgo on my map RIGHT NOW and il lcheck my triggers
ADDITION:
my tirrigers are and work... always set defenders to ally(teh computers) preserve trigger and then always order units at 1 move to 2 2 - 1 3 - 4 4 - 3 5 - 6 6 - 5 or what ever urs are. they will move, and no matter what if they are blocked the yattack trust me it works.
[right][snapback]573939[/snapback][/right]
Hmm, what do you mean exactly? I'm making a tower defense map and I'd like to know how to do this as well.
have your move triggers blah blah blah make sure its order MOVE and juts make the computer player allied, then if they can't get to their desitination, they'll blow through. simple.
Sorry Im late, I read your problem, sure you can complicate with all this attacking crap, but I got a better idea.
On the edge of the terrain put an unbuildable, walkable terrain. Thats right, its that ez
only problem with that is the ycan just bypass the defense completely, if you just do what i told you, it will work exactly as you want it, i just made my 24th defense map everyone works completely, and it uses the same exact method i told you.
Again, set the players to the computers allies. so...
computer player
always
set force 1(defenders) to allies
preservetriggers
and
computer player
always
order units at start move to end
preserve
or what ever our moving conditions are.
this will make them walk, and attack if you wall.
Ah, so that's what you meant. I wasn't quite sure until you actually posted an example of the triggers for it. I'll try it out on my own map when I can.
Hmm, does it work ok with at least somewhat complicated mazes for them to go through?
if the yget stuck... say they jam themselves they attack thats the tirggers ALL defenses use.. well pretty much.