示例#1
0
        public Pather.Graph.Path CalculatePath(Pather.Graph.Location iOrigin, Pather.Graph.Location iDestination, float sDist)
        {
            Pather.Graph.Path mypath = world.CreatePath(iOrigin, iDestination, sDist);

            /* We save the PathGraph. Stores every chunk of the map we used in the
             * PPather\PathInfo\{map} folder */
            world.Save();
            return(mypath);
        }
示例#2
0
文件: Form1.cs 项目: uvbs/babbot
        private void Form1_Load(object sender, EventArgs e)
        {
            Caronte.Caronte caronte = new Caronte.Caronte();
            caronte.Init("Expansion01");

            Pather.Graph.Path path = caronte.CalculatePath(new Pather.Graph.Location(240.94f, 2692.39f, 89.74f),
                                                           new Pather.Graph.Location(189.63f, 2690.94f, 88.71f));

            foreach (Pather.Graph.Location loc in path.locations)
            {
                Console.WriteLine("X: {0}\t\tY: {1}\t\tZ: {2}", loc.X, loc.Y, loc.Z);
            }
        }
示例#3
0
 public Pather.Graph.Path CalculatePath(Pather.Graph.Location iOrigin, Pather.Graph.Location iDestination, float sDist, float charHight, float charRadius)
 {
     Pather.Graph.Path mypath = world.CreatePath(iOrigin, iDestination, sDist, charHight, charRadius);
     world.Save();
     return(mypath);
 }