public class ManhattanDistanceAlgorithm extends Object implements IMoveAlgorithm
| Constructor and Description |
|---|
ManhattanDistanceAlgorithm() |
public Direction whereShouldIGo(List<Point> snake, Direction direction, Point food, int rows, int columns)
whereShouldIGo in interface IMoveAlgorithmsnake - lista de pontos ocupados pela cobra.direction - direção atual.food - ponto da comida.rows - número total de linhas.columns - número total de colunas.Copyright © 2013–2015 Tecgraf/PUC-Rio. All rights reserved.