public bool RevealCellsIfEqual(CellGuessHandler i_Guess, Player i_PlayerReveal) { string firstCellValue = r_CurrentBoard[i_Guess.GetRowGuess(0), i_Guess.GetColumnGuess(0)].GetStringIfRevealed(true); string secondCellValue = r_CurrentBoard[i_Guess.GetRowGuess(1), i_Guess.GetColumnGuess(1)].GetStringIfRevealed(true); bool isReavling = firstCellValue == secondCellValue; if (isReavling) { RevealCellState(i_Guess, true, i_PlayerReveal); m_RevealedCells += 2; } return(isReavling); }
public void RevealCellState(CellGuessHandler i_Guess, bool i_RevealCells, Player i_PlayerReveal = null) { for (int i = 0; i < i_Guess.CurrentGuess; i++) { r_CurrentBoard[i_Guess.GetRowGuess(i), i_Guess.GetColumnGuess(i)].RevealState(i_RevealCells, i_PlayerReveal); } }
public int GetRowGuess(int i_GuessNumber) { return(r_CellGuessManager.GetRowGuess(i_GuessNumber)); }