Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func NewSprite ¶ added in v0.1.0
func NewSprite() *spriteToDraw
Create a new sprite. Default to the turtle image and invisible.
func StartEbitenTurtleCanvas ¶
func StartEbitenTurtleCanvas(params CanvasParams, drawFunc func(turtlemodel.Canvas))
Start the Ebiten game. The drawFunc will be started as a go routine.
func TestEbitenTurtleCanvas ¶ added in v0.1.0
Types ¶
type CanvasParams ¶
type CanvasParams struct { Width int // pixels Height int // pixels ShowFPS bool // Show frame per second and other info in the top left corner. }
Turtle Window creation parameters
type SavedControlState ¶
type SavedControlState struct {
// contains filtered or unexported fields
}
Struct to hold ebiten key state information. It is used every frame during the update.
func (*SavedControlState) GetUserInput ¶
func (s *SavedControlState) GetUserInput(screenWidth, screenHeight int) (pressed, justPressed *turtlemodel.UserInput)
Generate a new struct for pressed and just pressed. It should be read only to everyone else.
Click to show internal directories.
Click to hide internal directories.