Versions in this module Expand all Collapse all v0 v0.1.0 Dec 9, 2023 Changes in this version + const COLUMNS_MAX + const PlayerOne + const PlayerTwo + const ROWS_MAX + const ScreenHeight + const ScreenWidth + var ColorBlue = color.RGBA + var ColorRed = color.RGBA + var ColorYellow = color.RGBA + var ErrTerminated = errors.New("terminated") + var LargeFont font.Face + var MediumFont font.Face + var SmallFont font.Face + func GetBoardState(board Board) (BoardState, []Piece) + func IsValidMove(state Board, player int, column int) bool + type Board [][]int + func AddPiece(board Board, player int, column int) Board + func NewBoard(state Board) Board + type BoardState int + const DrawState + const OngoingState + const PlayerOneWinState + const PlayerTwoWinState + type Game struct + State *GameState + Title string + func (g *Game) Draw(screen *ebiten.Image) + func (g *Game) Layout(outsideWidth, outsideHeight int) (screenWidth int, screenHeight int) + func (g *Game) Setup() + func (g *Game) StartGame() + func (g *Game) Update() (err error) + type GameState struct + Board *Board + BoardState BoardState + NextToPlay int + func NewGameState(board *Board, boardState BoardState, nextToPlay int) *GameState + type Piece struct + type Scene int + const GameOverScene + const PlayingScene