Hello
I'm currently designing a melee map, but I have encountered an issue with the pathing.
The map is quite big and the path to the opponent's base is S-shaped, which apparently makes the units unable to find a path to the target when asked to go across the whole map. Instead the end up standing outside the base trying to get in.
There is also destructible rocks that opens up short cuts, but while they're still up a full path can't be determined by the path finding algorithm, even though there is a big very clear road open.
Here's an art pad to explain the issue further: http://artpad.art.com/gallery/?lncpen9wwuc
(Press "skip to end" if you don't want to see my slow drawing)
Red filled circles = destructible rocks
B = bases
Green line = desired (closest) path (with destructibles up)
Purple line = actual path (failed to find the correct one)
So my question is, is there any way of "helping" the units finding the path, or is my only option to completely redesign the whole map?
The pathfinder will just cancel after a certain distance and report back: no valid path found and then the units will just walk in the diretion towards the target and get stuck in front of any wall/big object ...
You could add a trigger that redirects units along the S path when the target is too far away but that might feel weird for a melee map...
May I ask how you are testing this? In normal circumstances, what you're trying to do should work. The error you're encountering however, is one that's not uncommon - if the enemy player at the top base has got his ramp walled off, your units will calculate this in their pathing regardless of whether you have actually seen the wall-off. What might simply be happening is that you're testing the map against a player who is walling off his base, which causes the units to move to the point closest to their destination without even running into the wall-off. You may have never realized this and never even scouted for the wall off.
Alternatively, try swapping the bases around and going from the top base to the bottom - does the same error occur? The path might *actually* be blocked somewhere either in the middle of the map or between the two uppermost rock formations.
I'm testing it solo, so there most likely aren't a wall off. I also is trying to send an worker by right clicking on the map. Since the map is perfectly mirrored I doubt the error should only be one-way.
How long is the max path distance? Is there any way to add like way points to "help it out" a bit or something?
I'm testing it solo, so there most likely aren't a wall off. I also is trying to send an worker by right clicking on the map. Since the map is perfectly mirrored I doubt the error should only be one-way.
Try it. My point is that I don't really think there is a max pathing distance to speak off, and if there is, it definitely shouldn't occur in a map with only two bases. Obviously I don't know your map size, but I still think chances are slim. I think very much that something else is in play here, I'm just not sure what exactly.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Hello I'm currently designing a melee map, but I have encountered an issue with the pathing.
The map is quite big and the path to the opponent's base is S-shaped, which apparently makes the units unable to find a path to the target when asked to go across the whole map. Instead the end up standing outside the base trying to get in.
There is also destructible rocks that opens up short cuts, but while they're still up a full path can't be determined by the path finding algorithm, even though there is a big very clear road open.
Here's an art pad to explain the issue further: http://artpad.art.com/gallery/?lncpen9wwuc (Press "skip to end" if you don't want to see my slow drawing) Red filled circles = destructible rocks B = bases Green line = desired (closest) path (with destructibles up) Purple line = actual path (failed to find the correct one)
So my question is, is there any way of "helping" the units finding the path, or is my only option to completely redesign the whole map?
@hotet:
The pathfinder will just cancel after a certain distance and report back: no valid path found and then the units will just walk in the diretion towards the target and get stuck in front of any wall/big object ...
You could add a trigger that redirects units along the S path when the target is too far away but that might feel weird for a melee map...
May I ask how you are testing this? In normal circumstances, what you're trying to do should work. The error you're encountering however, is one that's not uncommon - if the enemy player at the top base has got his ramp walled off, your units will calculate this in their pathing regardless of whether you have actually seen the wall-off. What might simply be happening is that you're testing the map against a player who is walling off his base, which causes the units to move to the point closest to their destination without even running into the wall-off. You may have never realized this and never even scouted for the wall off.
Alternatively, try swapping the bases around and going from the top base to the bottom - does the same error occur? The path might *actually* be blocked somewhere either in the middle of the map or between the two uppermost rock formations.
@Mozared: Go
I'm testing it solo, so there most likely aren't a wall off. I also is trying to send an worker by right clicking on the map. Since the map is perfectly mirrored I doubt the error should only be one-way.
How long is the max path distance? Is there any way to add like way points to "help it out" a bit or something?
Try it. My point is that I don't really think there is a max pathing distance to speak off, and if there is, it definitely shouldn't occur in a map with only two bases. Obviously I don't know your map size, but I still think chances are slim. I think very much that something else is in play here, I'm just not sure what exactly.