Ejemplo n.º 1
0
 //对角线寻路
 public List <Vector2Int> DiagonallyFindPath(Vector2Int pointA, Vector2Int pointB,
                                             int[] canPassObstacleTypes,
                                             int[] canPassTerrainTypes)
 {
     return(AStarMapPathUtil.DiagonallyFindPath(this, pointA, pointB, canPassObstacleTypes,
                                                canPassTerrainTypes));
 }
Ejemplo n.º 2
0
        public static Action Test_DirectFindPath()
        {
            List <Vector2Int> list = AStarMapPathUtil.DirectFindPath(new AStarMapPath(grids), new Vector2Int(1, 1),
                                                                     new Vector2Int(4, 4), AStarMapPathConst.Critter_Can_Pass_Obstacle_Types,
                                                                     AStarMapPathConst.User_Can_Pass_Terrain_Types);

            return(() => { AStarUtil.GUIShowPointList(0, 0, 9, 9, list); });
        }