public static bool IsValidJump(PlayerMove i_ParseMove, char i_CoinType, Board i_Board) { bool isValidJump = true; Square middleSquare = i_ParseMove.calculateMiddleSquare(); Square squareToLandOn = i_ParseMove.NextSquare; if (!i_Board.IsEmptyAtSquare(squareToLandOn) || !i_Board.IsSquareContainCoinByType(middleSquare, i_CoinType)) { isValidJump = false; } return(isValidJump); }
public void EatCoin(PlayerMove i_CurrentMove) { Square squareToRemoveCoinFrom = i_CurrentMove.calculateMiddleSquare(); m_Board[squareToRemoveCoinFrom.RowIndex, squareToRemoveCoinFrom.ColumnIndex] = null; }