pieces

package
v0.0.0-...-f65e148 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 22, 2018 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ByColor

type ByColor map[string]ByName

ByColor represents a map of color name to ByName

type ByName

type ByName map[string]*pixel.Sprite

ByName represents a map of piece names to sprites

type Drawer

type Drawer struct {
	Black Set
	White Set
}

Drawer contains all chess piece sprites

func New

func New() Drawer

New constructs a ByColor (chess piece sprites)

type Set

type Set struct {
	King   *pixel.Sprite
	Queen  *pixel.Sprite
	Bishop *pixel.Sprite
	Knight *pixel.Sprite
	Rook   *pixel.Sprite
	Pawn   *pixel.Sprite
}

Set contains one sprite per type of piece

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL