chessica-0.1.0.0: A Library for Chess Game Logic
Copyright(c) Michael Szvetits 2023
LicenseBSD-3-Clause (see the file LICENSE)
Maintainertypedbyte@qualified.name
Stabilitystable
Portabilityportable
Safe HaskellSafe-Inferred
LanguageGHC2021

Chess.Rulebook

Description

Types and functions to define rulebooks for chess games.

Synopsis

Documentation

data Rulebook Source #

Represents a rulebook for a chess game.

Constructors

Rulebook 

Fields

  • newGame :: Game

    Creates a new chess game, according to the rulebook.

  • status :: Game -> Status

    Gets the status of a chess game, according to the rulebook.

  • updates :: Position -> Game -> [Update]

    Gets all possible updates (i.e., future game states) for a chess piece on a specified position, according to the rulebook.