Author Topic: PS Pathfinding  (Read 1395 times)

stefanjp

  • Wayfarer
  • *
  • Posts: 2
    • View Profile
PS Pathfinding
« on: July 17, 2009, 01:37:05 am »
Hi,
i am not sure, if this is the right forum section, but i hope to get an answer here most likely.
I am about to develope a RPG like game, based on the Crystal Space engine. I was thinking about implementing an path finding algorithm myself, but i relised that an efficient algorithm would be a very time consuming task. With pathfinding i mean a algorithm, that calculates a path from point A to point B on a map with obstacles. I don't need AI pathfinding. My question is: Does Crystal Space provide a pathfinding algorithm. How did the PS project implement pathfinding? I couldn't find anything in the source code. I would be glad if anybody could give me a hint, where to search for the PS implementation of pathfinding.

Thanks for your time,

stefanjp

weltall

  • Moderator
  • Veteran
  • *
  • Posts: 1671
    • View Profile
    • http://weltall.heliohost.org
Re: PS Pathfinding
« Reply #1 on: July 17, 2009, 07:50:50 am »
the npcclient folder is your destination.

stefanjp

  • Wayfarer
  • *
  • Posts: 2
    • View Profile
Re: PS Pathfinding
« Reply #2 on: July 17, 2009, 11:50:08 am »
Thanks for your answer. I was searching in the server and client folder. I guess the "pathfind.h" is included in the (players character) client too. I am curious, where the player path finding is processed (client or server). I did a bit of research on A*. The algorithm itself is not so hard to understand, but the implementation of pathfinding on a "poligon map" is hard to figure out for me. How can i canculate the graph (esp. the nodes = passable polygons). For one character a poligon may be passable, for another it isnt. Some ares are passable by walking over multiple poligons (when a single poligon is to small for the character). How can i consider this in the graph calculation. How can i disign my map to make pathfinding efficient? Is it possible to use polygons with different numbers of edges for path finding? Anybody has a link or some ideas for me?

Thanks in advance,

stefanjp

PS. I hope my english is readable  :D
« Last Edit: July 17, 2009, 11:51:51 am by stefanjp »

weltall

  • Moderator
  • Veteran
  • *
  • Posts: 1671
    • View Profile
    • http://weltall.heliohost.org
Re: PS Pathfinding
« Reply #3 on: July 17, 2009, 12:00:36 pm »
i suggest trying to contact someone who actually works on the npcclient like khaki. he would be more proper to answer your questions :)