grid

package
v0.0.0-...-9948f64 Latest Latest
Warning

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

Go to latest
Published: Jan 4, 2025 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Grid

type Grid struct {
	// contains filtered or unexported fields
}

func Deserialize

func Deserialize(w, h uint8, ser []byte) (*Grid, error)

func New

func New(w, h uint8, goalX, goalY uint8, nodes []node.Node) (*Grid, error)

func (*Grid) Duplicate

func (g *Grid) Duplicate() *Grid

func (*Grid) Get

func (g *Grid) Get(x, y uint8) *node.Node

func (*Grid) Goal

func (g *Grid) Goal() (uint8, uint8)

func (*Grid) Hash

func (g *Grid) Hash() string

func (*Grid) Height

func (g *Grid) Height() uint8

func (*Grid) Print

func (g *Grid) Print()

func (*Grid) Serialize

func (g *Grid) Serialize() []byte

func (*Grid) SetGoal

func (g *Grid) SetGoal(x, y uint8)

func (Grid) String

func (g Grid) String() string

func (*Grid) Transfer

func (g *Grid) Transfer(srcX, srcY, destX, destY uint8) *Grid

func (*Grid) Width

func (g *Grid) Width() uint8

Jump to

Keyboard shortcuts

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