general

package
v0.1.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Coord

type Coord = float32

Coord is a type for coordinates.

type Drawable

type Drawable[T image.Image] interface {
	Draw(image T)
}

Drawable is an interface that represents a drawable object.

type Frames

type Frames = int

Frames is a type for frames.

type ImageConfigure

type ImageConfigure[T image.Image] interface {
	InitImage() error
	Image() T
}

ImageConfigure is an interface that can initialize image from the temporary state of the entity (e.g. color.RGBA from color hex-string) and save the image to itself.

type Point

type Point struct {
	// X is a X coordinate.
	X Coord

	// Y is a Y coordinate.
	Y Coord
}

Point is a struct that represents a point.

type State

type State interface {
	// Drawable is an interface that represents a drawable object.
	Drawable[*ebiten.Image]

	// Update updates the state.
	Update() error

	// End returns true if the state is ended.
	End() bool
}

State is an interface that represents a state.

type TypeAttack

type TypeAttack int

TypeAttack is an enum that represents the type of attack.

type Widgets

type Widgets map[string]*ebiten.Image

Widgets represents a collection of widgets.

Jump to

Keyboard shortcuts

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