Path finding

2007-12-20
2013-04-23
  • The path finding is terrible, the selection too, you said that another guy/gal is responsible for programming that part, can I get in touch with her/him? Or better, can s/he join the forum? =)

    I have had a lot of graph/tree theory lately and am sure that I could help a bit. It's just that I suck at programming and don't know c, so I'd rather talk to the developer about the implementation rather than reading it...

     
    • Caerwyn
      Caerwyn
      2007-12-23

      Well, she's committed to, but hasn't actually started yet, so after the new version went out, I've started working on it again. 'Course, this being Christmastime and all, it's slow work, but check out the SVN trunk; some improvements are there, it doesn't suck *quite* so much now.....

       
    • Caerwyn
      Caerwyn
      2008-01-09

      Hey, can you try the latest SVN commits for pathfinding, tell me what you think? I think I'm starting to get a handle on it....

       
    • nikosgr
      nikosgr
      2008-01-09

      I agree with qubodup that the path finding was terrible...
      I can see in one previous SVN that you split all the map and when someone clicks on the map...the correct path is calculated by this split of map, isn't it? 

       
    • Caerwyn
      Caerwyn
      2008-01-10

      Yes, the split map is a graphic representation of the granular pathfinder. The last two days I've made some changes to this pathfinder -  is pathfinding still as bad as it was, using the current SVN build?

       
    • nikosgr
      nikosgr
      2008-01-10

      Yes , I use it..And I have to say that now is better...
      The game I think that is not very "heavy", so you can split the map more...What is your opinion mate?

       
    • Caerwyn
      Caerwyn
      2008-01-22

      Hi! Sorry for the silence, I've been away (and netless) for two weeks. What happens is the map gets split based on the dimensions of the unit doing the pathfinding, so larger objects will split the map into a larger grid, and smaller objects into a smaller grid. This way, (in the future at least) objects should be able to find a path between larger objects in a crowded space as long as there's a space big enough for them to squeeze through.

      At least that's the plan. As you've seen, though, easier said than done. :)

       
    • nikosgr
      nikosgr
      2008-02-05

      Ok mate...I would like to know if you increase 10% all of these grids then we have a better result...And what happens with if the resolution change? (I mean change the dimensions of the objects or they are fixed?)

      P.S. Good idea for you to classify the paths with the object's dimensions...

       
    • Caerwyn
      Caerwyn
      2008-02-05

      Ah! Well, the grids are generated by the larger of the units bounding box coordinates, either the X or Y direction, and I left it tight so that units could (well, in theory at least) find their way through tight spaces, if a player built their buildings close together. You know, the digital equivalent of nipping up the back alley rather than walking down the roundabout.

      If I increase the resolution by 10% it does make a better path, it's plain to see, but then the units make even bigger circles around the obstacle, and it looks kinda strange. I need to fix the fundamental problem with the pathfinder, and I'm happy to say that in the last five days or so, I've rewritten the granular pathfinder (again), and I think most of the problems are cleared up, as I've been able to turn the AI back on and found that pathfinding works pretty good with it. I just need to fix a problem with a crash happening with the timed message display system and a bug where the AI will stop where they are if the path comes back blank, and then I'll be posting a new version for trial!

      Can you compile from SVN? I'd really like some feedback on the work over the last five days if you can! :)

       
    • Compiles and runs on 32 bit ubuntu 7.10

      Too sleepy to try to make it crash right now =)

       
    • Caerwyn
      Caerwyn
      2008-02-08

      Found more bugs with the pathfinder....try Monday or Tuesday, as I can't (won't) commit to SVN while the program's as heavily loaded with debug code as it is right now (I'm getting a whopping 2 frames per second on a 2GHz processor thanks to the debug lines enabled).

       
    • nikosgr
      nikosgr
      2008-02-14

      Ok mate...
      I saw your job...
      but i'm waiting the latest to compare the path finding :)