| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
BishBosh.State.Position
Description
AUTHOR- Dr. Alistair Ward
DESCRIPTION
- Defines the state of the game, without regard to how it arrived there; https://chessprogramming.wikispaces.com/Chess+Position.
- Games with the same position have the same opportunities.
- N.B.: pieces are fungible, i.e. they lack identity, so the location of identical pieces may be exchanged, without altering the position.
- data Position x y
- mkPosition :: (Enum x, Enum y, Ord x, Ord y) => LogicalColour -> MaybePieceByCoordinates x y -> CastleableRooksByLogicalColour x -> Maybe (Turn x y) -> Position x y
Types
Data-types
- The state of the game, without regard to how it arrived there; https://chessprogramming.wikispaces.com/Chess+Position.
- Games with the same position may be considered to have converged, since they now have equal opportunity.
Instances
| (Ix x, Enum x, Enum y, Ord y) => Hashable2D Position x y Source # | |
| (Enum x, Enum y, Ord x, Ord y) => Eq (Position x y) Source # | |
| (Enum x, Enum y, Ord x, Ord y) => Ord (Position x y) Source # | |
| (NFData x, NFData y) => NFData (Position x y) Source # | |
| (Enum x, Enum y, Ord x, Ord y) => ReflectableOnX (Position x y) Source # | |
Functions
Constructors
Arguments
| :: (Enum x, Enum y, Ord x, Ord y) | |
| => LogicalColour | The logical colour of the next player to move. |
| -> MaybePieceByCoordinates x y | |
| -> CastleableRooksByLogicalColour x | |
| -> Maybe (Turn x y) | The last turn made. |
| -> Position x y |
Constructor.