Exemplo n.º 1
0
 public BaseTile getClosestOpenTile(BaseTile ToCheck, TeamInfo T, GetLocalTiles locals)
 {
     List<BaseTile> open = locals(ToCheck, T);
     BaseTile returnable = null;
     int minVal = int.MaxValue;
     open.ForEach(delegate(BaseTile obj) {
         if(ToCheck.calcHueristic(ToCheck, obj) < minVal){ returnable = obj; minVal = ToCheck.calcHueristic(ToCheck, obj);}
     });
     return returnable;
 }