Menu

PlayerKnowledge

Jan Schäfer

The class PlayerKnowledge provides a lot of standard information that can be used by any AI player.

  • the player position (fore hand, middle hand, rear hand)
  • the highest bid of each player during the bidding phase
  • cards, that have been played by the players (certain information, cards have been seen by all players)
  • potential card positions, i.e. all cards that could be in a certain position (uncertain information, one card can be on more than one hand)
  • the card that has been played by the player to the left of the actual player (must always be the first trick card)
  • the card that has been played by the player to the right of the actual player (can be the first or the second trick card, depending on the above mentioned card)
  • the number of trump cards that are still out (including the ones on the players hand!)
  • number of cards for every suit on players hand
  • points for every suit on players hand
  • the history of all tricks that have already been completed during the current game

Besides that immediate information, based upon that there are several questions, that are answered in methods:

  • Has a given card already been played? (or not played --> outstanding)
  • Has a given card already been played by a specific player?
  • Can a given card only be held by a specific player?

Related

Wiki: Main_Page

MongoDB Logo MongoDB