diff --git a/common/src/algorithms/movementDirection.ts b/common/src/algorithms/movementDirection.ts index d9f0dda..2164ca4 100644 --- a/common/src/algorithms/movementDirection.ts +++ b/common/src/algorithms/movementDirection.ts @@ -8,7 +8,7 @@ * @returns An object containing the number of ships that are on each side of * the target ship */ -function countShips(board: string[], shipLocation: number) { +function countShips(board: any[], shipLocation: number) { return { left: board.slice(1, shipLocation - 1).filter(x => x != null).length, right: board.slice(shipLocation + 1).filter(x => x != null).length, @@ -27,7 +27,7 @@ function countShips(board: string[], shipLocation: number) { * - `0` = Not moving * - `1` = Towards the Warp Gate */ -export function determineDirection(board: string[], shipLocation: number) { +export function determineDirection(board: any[], shipLocation: number) { let delta = 1; while (true) {