world

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jun 29, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	WorldNone = iota
	WorldGrass
)

Variables

This section is empty.

Functions

func Clear

func Clear()

func Draw

func Draw(screen *ebiten.Image) error

func IsCollision

func IsCollision(x, y float64) bool

func Update

func Update()

func X

func X() float64

func Y

func Y() float64

Types

type SpriteData

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

type World

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

func At

func At(x, y float64) *World

func HID

func HID(hid string) *World

func New

func New(worldType int) (*World, error)

func Worlds

func Worlds() []*World

func (*World) AnimationAttack

func (n *World) AnimationAttack() error

func (*World) AnimationGotHit

func (n *World) AnimationGotHit() error

func (*World) Draw

func (n *World) Draw(screen *ebiten.Image) error

func (*World) EntityID

func (n *World) EntityID() uint

func (*World) HID

func (n *World) HID() string

func (*World) IsHit

func (n *World) IsHit(x, y float64) bool

func (*World) Position

func (n *World) Position() (float64, float64)

func (*World) SHeight

func (n *World) SHeight() int

func (*World) SWidth

func (n *World) SWidth() int

func (*World) SetPosition

func (n *World) SetPosition(x, y float64)

func (*World) Update

func (n *World) Update()

func (*World) X

func (n *World) X() float64

func (*World) Y

func (n *World) Y() float64

type WorldData

type WorldData struct {
	Tilemap *SpriteData
	Icon    *SpriteData
}

Jump to

Keyboard shortcuts

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