Class Player

java.lang.Object
ca.uqam.info.model.Player

public class Player extends Object
Represents a player in the Skyjo game. This class manages a player's card grid, including card placement, visibility state, and score calculation. Each player has a fixed grid size that cannot change during the game (though the specification mentions elimination of rows/columns, this implementation keeps dimensions constant for simplicity).
Version:
1.3
Author:
Mohamed Latif Diallo, Hamza Afif, Ussel Sabbat
  • Constructor Details

    • Player

      public Player(String names, int sizeColumnMax, int sizeRowMax)
      Constructor for the Player.
  • Method Details

    • getPlayerCard

      public HandPlayerCards getPlayerCard()
      Getter the PlayerCard
      Returns:
      HandPlayerCards
    • addCard

      public void addCard(CardImpl cards)
      Helper method to add a carte in the PlayerCard
    • getNamesPlayer

      public String getNamesPlayer()
      Getter the name of the player
      Returns:
      String
    • getPlayerScore

      public int getPlayerScore()
      Getter the score of the player
      Returns:
      int
    • getSizeRowMax

      public int getSizeRowMax()
      Getter the size (number of row) of the player Card
      Returns:
      int
    • getSizeColumnMax

      public int getSizeColumnMax()
      Getter the size (number of column) of the player Card
      Returns:
      int
    • revealdRandomPlayerCards

      public void revealdRandomPlayerCards()
      Helper method to reveald a random card in the player card
    • revealdRemaidCard

      public void revealdRemaidCard()
      Helper method to reveald all the remain card in the player card
    • reduceColumn

      public void reduceColumn(int index)
    • reduceRow

      public void reduceRow()