No-Go-Zones and overriding the Pathfinding Algorithm

Discussion in 'Planetary Annihilation General Discussion' started by TheLambaster, March 23, 2013.

  1. TheLambaster

    TheLambaster Active Member

    Messages:
    489
    Likes Received:
    131
    Hey, I just watched the latest PA LiveStream. Please note that I did understand (on an intuitive level) what they were talking about, so don't quit reading what I have to say prematurely.

    1. no-go-zones

    During the stream some viewer asked the question, if players would be able to manually add cost to the navmesh. I think John misjudged the questioner for not having understood the concept (John assumed the questioner thought this would be some actual control feature for the player). I rather think this guy wanted to know, if this very thing could be introduced as a feature. And THIS I think is actually a brilliant idea! This way you could create no-go-zones for example. Or "only-go-if-no-better-option-zones". I suggest considering this very question again. After all we want to have lots of control power for the player, right?


    2. overriding the pathfinding algorithm

    In the last example fro the flowfield algorithm about the choke points they said, units might decide to take routes around the choke point based on the flowfield (When it takes longer for the group of units to get to the point of destination if some of them wait until the can pass through the choke rather than take a different route around it). My immediate response-thought to this was: "Wait, maybe I do not want my units to take a different route!". This does not only apply to the case of a choke point of course, but rather to many situations. Therefore it might be good to have the option to partly (!!) override the pathfinding algorithm and force units to take the most direct route possible, but still in an efficient manner.


    I think the latter is a needed option and the former would be a welcome one. What do you think?
  2. syox

    syox Member

    Messages:
    859
    Likes Received:
    3
    i like it. But the costs are currently only caluclated serversides, to manipulate it you have to view it client sides, else you would fish in muddy waters.
  3. TheLambaster

    TheLambaster Active Member

    Messages:
    489
    Likes Received:
    131
    Not quite... you could add an extra layer of "player defined cost zones". The player does not need to see the cost calculated by the game itself.
  4. syox

    syox Member

    Messages:
    859
    Likes Received:
    3
    But your units still may go through them because you can't see the serverside stuff.
    Well you could paste unpassable cost(255) but this may hinder a fast retreat. Nevertheless i am in for it. But it may get hard to implement.
  5. x3kj

    x3kj New Member

    Messages:
    24
    Likes Received:
    0
    No, it's a horrible idea. The enemy uses it as well so it's easy to bottleneck him without apparent reason for the enemy.

    If you have a button "take alternative route" on/off for a formation that could work, but directly painting is bad. You can set waypoints close to each other.
    Last edited: March 23, 2013
  6. TheLambaster

    TheLambaster Active Member

    Messages:
    489
    Likes Received:
    131
    ?? This would be player-specific of course ??

    @ syox:

    Ah okay, now I see. You mean, I do not know, how high the cost I paint needs to be relative to the game-calculated areas (that might have higher cost than what I put down in the area I am painting with cost) to be higher than those.
    For fast retreats you could also have a specific "ignore user defined cost".
    Last edited: March 23, 2013
  7. syox

    syox Member

    Messages:
    859
    Likes Received:
    3
    Think over it again. They talked about adding cost dynamicly, and having many cummulative cost maps aka flowfields. You wouldn't want to add this to the general costmap of the planet.

    @thelambaster, yep that what was i meant.
  8. torrasque

    torrasque Active Member

    Messages:
    337
    Likes Received:
    36
    That's what I understood too. it could be quite useful.

    Well, I think we must keep in mind that you can still place waypoints. If you really want to pass through a certain bottleneck, just put an intermediary goals in the middle of the bottleneck.
  9. bmb

    bmb Well-Known Member

    Messages:
    1,497
    Likes Received:
    219
    Units going off on their own is always(!) a bad idea. Do rectify.
  10. neutrino

    neutrino low mass particle Uber Employee

    Messages:
    3,123
    Likes Received:
    2,687
    See, I don't even need to respond in these threads because you guys get it.

    Sometimes the simple solution is the correct solution. You can put down waypoints to give more fine control.
  11. bmb

    bmb Well-Known Member

    Messages:
    1,497
    Likes Received:
    219
    That requires understanding of why they go off on their own in the first place.

    It's a very unintuitive solution.
  12. KNight

    KNight Post Master General

    Messages:
    7,681
    Likes Received:
    3,268
    How is it not?

    Units go to the Goal, so naturally the more you putting into it(via extra waypoints) the more you'll get out of it.

    Mike
  13. bmb

    bmb Well-Known Member

    Messages:
    1,497
    Likes Received:
    219
    The video shows it off perfectly, there are two mountains and a pass inbetween. All the units are on one side and are ordered to the other side of the pass, with the order passing straight through the pass.

    Several units go around seemingly of their own accord.

    How is this intuitive?

    To propose a solution I think it would be a good idea to enforce a minimum level of coherence to a group of units that have been ordered to go somewhere together.
  14. TheLambaster

    TheLambaster Active Member

    Messages:
    489
    Likes Received:
    131
    Very right. You might want to give a move order to a large group of units and don't want the group to separate due to flow field. Therefore different options for move actiosn might be in order, like "All units move individually to quickly reach the waypoint." or "All units stay in cohesion (not necessarily formation!) and reach waypoint as a group.".
  15. yogurt312

    yogurt312 New Member

    Messages:
    565
    Likes Received:
    2
    so basically formation control?
  16. TheLambaster

    TheLambaster Active Member

    Messages:
    489
    Likes Received:
    131
    If you consider cohesion a form of formation, then yes. Would be pretty cool if you had a cohesion slider for a group of selected units that diterimes the groups movement behavior in regards to the flowfield. So movement efficiency vs. cohesion, basically. The slider then causes the selected units to either behave like quicksilver, water or sand (and some stuff in between). Like so:


    [​IMG]

    link to larger version:

    http://i.imgur.com/z6BHcmn.png
  17. blodgivarjens

    blodgivarjens New Member

    Messages:
    4
    Likes Received:
    0
    Just a quick edit to above pic to show how this unit behaviour is easily created with waypoints:

    [​IMG]

    It seems unlikely(and costly) that units will go around the 'hills', turn around, collide with units going the quick route, reach the intermediate waypoint and then finally make their way to the goal.
  18. TheLambaster

    TheLambaster Active Member

    Messages:
    489
    Likes Received:
    131
    This was a simplified example. When you have longer distances with more obstacles you don't want to put down a bazillion waypoints just so that your selection group does not split up.

    Edit: Also, you might even want to behave your section group more like sand or water. this you cannot achieve without lots of micro if you cannot set the degree of cohesion for that selection group.

    After all this game is supposed to be a next-gen RTS, right? So come up with next gen control mechanisms...
  19. syox

    syox Member

    Messages:
    859
    Likes Received:
    3
    Even with that units could go the way around, this is based on the implenetation of Flowfield and how collision detection is done.
    If collision detection is done by dynamicly adding values to the flowfield, it could happen even for bigger armies.
    If its computed other ways its unlikely to happen.

    Also group and formation handling could influence this.

    All said above is based on my view of the flowfield. And could be wrong.
  20. TheLambaster

    TheLambaster Active Member

    Messages:
    489
    Likes Received:
    131
    Judging from what they said in the stream it is probably right though. Unfortunately Neutrino said there was no need for him to say anything here, because we had figured it out alone... I rather think there is need indeed. As it stands at the moment I fear for units that have a mind on their own so to speak. Which of cause has its merits at times. But at others it does not, thus we might need mechanisms to get them 'back under control'.
    And cohesion control, cost-painter/ no-go-zones and "take most direct route"-move commands are such.

Share This Page