Documentation ¶
Index ¶
Constants ¶
View Source
const ( ScreenWidth = 640 ScreenHeight = 360 )
View Source
const ( DT = 0.1 WINDOWSIZE = 256 WINDOWSCALE = 3 TILESIZE = 16 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GameScene ¶
type GameScene struct {
// contains filtered or unexported fields
}
func NewGameScene ¶
func NewGameScene() *GameScene
type GameState ¶
type GameState struct { SceneManager *SceneManager Input *Input }
type GamepadScene ¶
type GamepadScene struct {
// contains filtered or unexported fields
}
func (*GamepadScene) Draw ¶
func (s *GamepadScene) Draw(screen *ebiten.Image)
func (*GamepadScene) Update ¶
func (s *GamepadScene) Update(state *GameState) error
type Input ¶
type Input struct {
// contains filtered or unexported fields
}
Input manages the input state including gamepads and keyboards.
func (*Input) GamepadIDButtonPressed ¶
func (i *Input) GamepadIDButtonPressed() ebiten.GamepadID
GamepadIDButtonPressed returns a gamepad ID where at least one button is pressed. If no button is pressed, GamepadIDButtonPressed returns -1.
func (*Input) IsRotateLeftJustPressed ¶
func (*Input) IsRotateRightJustPressed ¶
func (*Input) StateForDown ¶
func (*Input) StateForLeft ¶
func (*Input) StateForRight ¶
type Player ¶
type SceneManager ¶
type SceneManager struct {
// contains filtered or unexported fields
}
func (*SceneManager) Draw ¶
func (s *SceneManager) Draw(r *ebiten.Image)
func (*SceneManager) GoTo ¶
func (s *SceneManager) GoTo(scene Scene)
func (*SceneManager) Update ¶
func (s *SceneManager) Update(input *Input) error
type TitleScene ¶
type TitleScene struct {
// contains filtered or unexported fields
}
func (*TitleScene) Draw ¶
func (s *TitleScene) Draw(r *ebiten.Image)
func (*TitleScene) Update ¶
func (s *TitleScene) Update(state *GameState) error
type WorldPlatformer ¶
type WorldPlatformer struct { Space *resolv.Space Player *Player FloatingPlatform *resolv.Object FloatingPlatformTween *gween.Sequence }
func NewWorldPlatformer ¶
func NewWorldPlatformer() *WorldPlatformer
func (*WorldPlatformer) Draw ¶
func (world *WorldPlatformer) Draw(screen *ebiten.Image)
func (*WorldPlatformer) DrawPolygon ¶
func (world *WorldPlatformer) DrawPolygon(screen *ebiten.Image, polygon *resolv.ConvexPolygon, color color.Color)
func (*WorldPlatformer) Init ¶
func (world *WorldPlatformer) Init()
func (*WorldPlatformer) Update ¶
func (world *WorldPlatformer) Update()
Source Files ¶
Click to show internal directories.
Click to hide internal directories.