示例#1
0
        public Pathfinding(IPathfindingMap Map, IEnumerable <int> targets, int origin = -1)
        {
            this.Map = Map;
            Nodes    = new Node[Map.NodeCount()];

            Dijkstra(targets, 0);
        }
示例#2
0
        public Pathfinding(IPathfindingMap Map, int target, int origin)
        {
            this.Map = Map;
            Nodes    = new Node[Map.NodeCount()];
            var watch = System.Diagnostics.Stopwatch.StartNew();

            AStar(target, origin, 1000);
            stat_nbAstar++;
            stat_timeAstar += watch.ElapsedMilliseconds;
        }
示例#3
0
 public Pathfinding(IPathfindingMap Map, int target, int origin)
 {
     this.Map = Map;
     Nodes = new Node[Map.NodeCount()];
     var watch = System.Diagnostics.Stopwatch.StartNew();
     AStar(target, origin, 1000);
     stat_nbAstar++;
     stat_timeAstar += watch.ElapsedMilliseconds;
 }
示例#4
0
        public Pathfinding(IPathfindingMap Map, IEnumerable<int> targets, int origin = -1)
        {
            this.Map = Map;
            Nodes = new Node[Map.NodeCount()];

            Dijkstra(targets, 0);
        }