2048-ai: github.com/xwjdsh/2048-ai/grid Index | Files

package grid

import "github.com/xwjdsh/2048-ai/grid"

Index

Package Files

grid.go

type Direction Uses

type Direction int
const (
    UP  Direction = iota
    RIGHT
    DOWN
    LEFT

    NONE
)

type Grid Uses

type Grid struct {
    Data [4][4]int `json:"data"`
}

func (*Grid) Clone Uses

func (g *Grid) Clone() *Grid

func (*Grid) Max Uses

func (g *Grid) Max() int

func (*Grid) Move Uses

func (g *Grid) Move(d Direction) bool

func (*Grid) VacantPoints Uses

func (g *Grid) VacantPoints() []utils.Point

Package grid imports 1 packages (graph) and is imported by 2 packages. Updated 2017-10-27. Refresh now. Tools for package owners.