the common ontology: understanding the communication between game server and client player
The Common
directory contains the materials that define
the common ontology between external players and the server.
player-interface
describes how the service side interacts with playersrules
a data representation for both checking the legality of turns and planning themgame-state
a data representation of game states: board, ordering of players, knowledge about playersinternal-player
a representation of the knowledge about the players currently in the gameboard
a representation of the game boardfish
basic constants for the fish tilespenguin
basic constants for the players' avatars
The API assumes the following protocols for the collaboration of the
Admin
components and Players
:
protocol-start-tournament
~~ signing up for the tournamentprotocol-run-tournament
~~ starting the round of gamesprotocol-launch-game
~~ launching an individual game, set-up phaseprotocol-play-turn
~~ playing a turn during an individual gameprotocol-end-tournament
~~ ending the tournament
A participant has access to this folder because it fully specifies the rules of engagement.
Note The protocol part reveals too much about the internal organization but none of these revelations should affect safety, security, or fairness.
file | purpose |
---|---|
board.rkt | a board representation for "Fish.com" |
call-in-order.rkt | a trace contract that checks the "referee promise" of calling all players |
fish.rkt | represents tiles with fish on them |
game-state.rkt | represent the game state for "Fish.com" |
internal-player.rkt | represents the "ground truth" state of players: |
penguin.rkt | characters that eat fish |
player-interface-error-reporting.rkt | print the history of how we got to an error in a trace contract |
player-interface.rkt | on the Administrative side, the player has contact with |
rules.rkt | the game rules, represented complete games as lazy game trees |