game

package
v0.0.0-...-38bf041 Latest Latest
Warning

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

Go to latest
Published: Feb 20, 2023 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BossFight

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

func (*BossFight) Init

func (b *BossFight) Init() tea.Cmd

func (*BossFight) Update

func (b *BossFight) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (*BossFight) View

func (b *BossFight) View() string

type BossKeyMap

type BossKeyMap struct {
	Fight key.Binding
}

func (BossKeyMap) FullHelp

func (b BossKeyMap) FullHelp() [][]key.Binding

func (BossKeyMap) ShortHelp

func (b BossKeyMap) ShortHelp() []key.Binding

type Game

type Game struct {
	Dead bool
	Won  bool
	// contains filtered or unexported fields
}

func NewGame

func NewGame() *Game

func (*Game) Init

func (g *Game) Init() tea.Cmd

func (*Game) Update

func (g *Game) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (*Game) View

func (g *Game) View() string

type GameKeyMap

type GameKeyMap struct {
	Shop    key.Binding
	Forward key.Binding
	Quit    key.Binding
}

func (GameKeyMap) FullHelp

func (k GameKeyMap) FullHelp() [][]key.Binding

func (GameKeyMap) ShortHelp

func (k GameKeyMap) ShortHelp() []key.Binding

type Shop

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

func (*Shop) Init

func (s *Shop) Init() tea.Cmd

func (*Shop) Update

func (s *Shop) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (*Shop) View

func (s *Shop) View() string

type ShopKeyMap

type ShopKeyMap struct {
	Back key.Binding
}

func (ShopKeyMap) FullHelp

func (k ShopKeyMap) FullHelp() [][]key.Binding

func (ShopKeyMap) ShortHelp

func (k ShopKeyMap) ShortHelp() []key.Binding

ShortHelp returns keybindings to be shown in the mini help view. It's part of the key.Map interface.

Jump to

Keyboard shortcuts

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