public static Action Test_GetAroundFreePointList() { List <Vector2Int> list = AStarUtil.GetAroundFreePointList(new AStarMapPath(grids), new Vector2Int(2, 2), 2, AStarMapPathConst.Critter_Can_Pass_Obstacle_Types, AStarMapPathConst.User_Can_Pass_Terrain_Types); return(() => { AStarUtil.GUIShowPointList(0, 0, 9, 9, list); }); }
public static Action Test_GetRangeFreePointList() { List <Vector2Int> pointList = AStarUtil.GetRangeFreePointList(new AStarMapPath(grids), 0, 0, 4, 4, null, AStarMapPathConst.Critter_Can_Pass_Obstacle_Types, AStarMapPathConst.User_Can_Pass_Terrain_Types); return(() => { AStarUtil.GUIShowPointList(0, 0, 9, 9, pointList); }); }
public static Action Test_GetLinePointList() { Vector2Int a_point = new Vector2Int(-4, -4); Vector2Int b_point = new Vector2Int(3, 2); List <Vector2Int> point_list = AStarUtil.GetLinePointList(a_point, b_point); return(() => { AStarUtil.GUIShowPointList(-5, -5, 5, 5, point_list); }); }
public static Action Test_GetArcPointList2() { Vector2Int center_point = Vector2Int.zero; int radius = 3; List <Vector2Int> point_list = AStarUtil.GetArcPointList2(center_point, radius); return(() => { AStarUtil.GUIShowPointList(-5, -5, 5, 5, point_list); }); }
public static Action Test_GetMostLinePassPoint() { Vector2Int point = AStarUtil.GetMostLinePassPoint(new AStarMapPath(grids), new Vector2Int(0, 0), new Vector2Int(4, 4), AStarMapPathConst.Critter_Can_Pass_Obstacle_Types, AStarMapPathConst.User_Can_Pass_Terrain_Types); return(() => { AStarUtil.GUIShowPointList(0, 0, 9, 9, point); }); }
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); }); }
public static Action Test_Find() { AStarImpl astar = new AStarImpl(new AStarMapPath(grids), default(AStarHType), AStarMapPathConst.Critter_Can_Pass_Obstacle_Types, AStarMapPathConst.User_Can_Pass_Terrain_Types); List <Vector2Int> list = astar.Find(1, 1, 3, 4); return(() => { AStarUtil.GUIShowPointList(0, 0, 9, 9, list); }); }
public static Action Test_GetExtendPoint() { Vector2Int a_point = new Vector2Int(-4, -4); Vector2Int b_point = new Vector2Int(3, 2); Vector2Int target_point = AStarUtil.GetExtendPoint(a_point, b_point, 2); return(() => { AStarUtil.GUIShowPointList(-5, -5, 5, 5, new List <Vector2Int>() { target_point }); }); }
public static Action Test_FindAroundFreePoint() { Vector2Int?point = AStarUtil.FindAroundFreePoint(new AStarMapPath(grids), new Vector2Int(2, 2), 2, null, AStarMapPathConst.Critter_Can_Pass_Obstacle_Types, AStarMapPathConst.User_Can_Pass_Terrain_Types); return(() => { if (point != null) { AStarUtil.GUIShowPointList(0, 0, 9, 9, point.Value); } }); }
public static Action Test_GetRandomMovePoint() { Vector2Int?point = AStarUtil.GetRandomMovePoint(new AStarMapPath(grids), new Vector2Int(0, 0), new Vector2Int(3, 3) , 2, AStarMapPathConst.Critter_Can_Pass_Obstacle_Types, AStarMapPathConst.User_Can_Pass_Terrain_Types); return(() => { if (point != null) { AStarUtil.GUIShowPointList(0, 0, 9, 9, new List <Vector2Int>() { point.Value }); } }); }
public static Action Test_GetNeighborList() { List <Vector2Int> pointList = AStarUtil.GetNeighborList(new Vector2Int(2, 2)); return(() => { AStarUtil.GUIShowPointList(0, 0, 9, 9, pointList); }); }