player

package
v0.0.0-...-af9548b Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Player

type Player struct {
	Name, Region string
	Health       int8
	Cash, Week   int
	Inventory    map[string]int
	Table        *table.Table
}

func New

func New(name string) *Player

func (*Player) BuyWeapon

func (p *Player) BuyWeapon(s *store.Store, w *store.Weapon, qty int) error

func (*Player) Damage

func (p *Player) Damage(value int8)

func (*Player) Move

func (p *Player) Move(region string) error

func (*Player) SellWeapon

func (p *Player) SellWeapon(s *store.Store, w *store.Weapon, qty int) error

func (*Player) UpdateTable

func (p *Player) UpdateTable()

Jump to

Keyboard shortcuts

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