View/GamePVAIView.java
public void displayTotalScores(){
        if(ply1WinCount == 3){
            Alert alert = new Alert(Alert.AlertType.NONE, "Player 1 has won \nPlayer 1 score: " + ply1WinCount +"\nAI score: " + aiWinCount);
            alert.getDialogPane().getStylesheets().add("/View/stylesheet.css");
            createEndAlert(alert);
            plyStreak++;
            AIStreak=0;
            AIGamesPlayed++;
            AIRoundsWon++;
        }
        else if(aiWinCount == 3){
            Alert alert = new Alert(Alert.AlertType.NONE, "The AI has won\nPlayer 1 score: " + ply1WinCount +"\nAI score: " + aiWinCount);
            alert.getDialogPane().getStylesheets().add("/View/stylesheet.css");
            createEndAlert(alert);
            plyStreak = 0;
            AIStreak++;
            AIGamesPlayed++;
            AIRoundsLost++;
        }
    }
/*Once either player has won three rounds an alert with the scores is created.
     *The game counters are changed accordingly
     */
Once either player has won three rounds an alert with the scores is created.
The game counters are changed accordingly
Once either player has won three rounds an alert with the scores is created . The game counters are changed accordingly
public void displayTotalScores(){
        if(ply1WinCount == 3){
            Alert alert = new Alert(Alert.AlertType.NONE, "Player 1 has won \nPlayer 1 score: " + ply1WinCount +"\nAI score: " + aiWinCount);
            alert.getDialogPane().getStylesheets().add("/View/stylesheet.css");
            createEndAlert(alert);
            plyStreak++;
            AIStreak=0;
            AIGamesPlayed++;
            AIRoundsWon++;
        }
        else if(aiWinCount == 3){
            Alert alert = new Alert(Alert.AlertType.NONE, "The AI has won\nPlayer 1 score: " + ply1WinCount +"\nAI score: " + aiWinCount);
            alert.getDialogPane().getStylesheets().add("/View/stylesheet.css");
            createEndAlert(alert);
            plyStreak = 0;
            AIStreak++;
            AIGamesPlayed++;
            AIRoundsLost++;
        }
    }
public void displayTotalScores ( ) { if ( ply1WinCount == 3 ) { Alert alert = new Alert ( Alert . AlertType . NONE , "Player 1 has won \nPlayer 1 score: " + ply1WinCount + "\nAI score: " + aiWinCount ) ; alert . getDialogPane ( ) . getStylesheets ( ) . add ( "/View/stylesheet.css" ) ; createEndAlert ( alert ) ; plyStreak ++ ; AIStreak = 0 ; AIGamesPlayed ++ ; AIRoundsWon ++ ; } else if ( aiWinCount == 3 ) { Alert alert = new Alert ( Alert . AlertType . NONE , "The AI has won\nPlayer 1 score: " + ply1WinCount + "\nAI score: " + aiWinCount ) ; alert . getDialogPane ( ) . getStylesheets ( ) . add ( "/View/stylesheet.css" ) ; createEndAlert ( alert ) ; plyStreak = 0 ; AIStreak ++ ; AIGamesPlayed ++ ; AIRoundsLost ++ ; } }
Once either player has won three rounds an alert with the scores is created.
Once either player has won three rounds an alert with the scores is created .