board

package
v0.0.0-...-53b8cb7 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package board handles the game board and all interactions.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Board

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

Board represents the game board and all its state.

func New

func New(engine *engine.Engine, accountID common.Address) (*Board, error)

New contructs a game board and renders the board.

func (*Board) Events

func (b *Board) Events(event string, address common.Address)

Events handles any events from the websocket. This function should be registered with any code receiving the web socket events.

func (*Board) Run

func (b *Board) Run() chan struct{}

Run starts a goroutine to handle terminal events. This is a blocking call.

func (*Board) Shutdown

func (b *Board) Shutdown()

Shutdown tearsdown the game board.

Jump to

Keyboard shortcuts

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