Documentation ¶
Index ¶
- type EbitenGame
- func (g *EbitenGame) Draw(screen *ebiten.Image)
- func (g *EbitenGame) GetNextSpriteID() int
- func (g *EbitenGame) GetSpriteCmdChannel() chan any
- func (g *EbitenGame) Layout(outsideWidth, outsideHeight int) (int, int)
- func (g *EbitenGame) PressedUserInput() *models.UserInput
- func (g *EbitenGame) RunGame()
- func (g *EbitenGame) TellGameToExit()
- func (g *EbitenGame) Update() error
- type GameInitStruct
- type SavedControlState
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EbitenGame ¶
type EbitenGame struct {
// contains filtered or unexported fields
}
func NewGame ¶
func NewGame(init GameInitStruct) *EbitenGame
func (*EbitenGame) Draw ¶
func (g *EbitenGame) Draw(screen *ebiten.Image)
func (*EbitenGame) GetNextSpriteID ¶
func (g *EbitenGame) GetNextSpriteID() int
func (*EbitenGame) GetSpriteCmdChannel ¶
func (g *EbitenGame) GetSpriteCmdChannel() chan any
func (*EbitenGame) PressedUserInput ¶
func (g *EbitenGame) PressedUserInput() *models.UserInput
func (*EbitenGame) RunGame ¶
func (g *EbitenGame) RunGame()
This function will not return. It must be run on the main thread.
func (*EbitenGame) TellGameToExit ¶
func (g *EbitenGame) TellGameToExit()
func (*EbitenGame) Update ¶
func (g *EbitenGame) Update() error
type GameInitStruct ¶
type SavedControlState ¶
type SavedControlState struct {
// contains filtered or unexported fields
}
func (*SavedControlState) GetUserInput ¶
func (s *SavedControlState) GetUserInput(screenWidth, screenHeight int) (pressed, justPressed *models.UserInput)
Generate a new struct for pressed and just pressed. then it becomes read only to everyone else.
Click to show internal directories.
Click to hide internal directories.