Documentation ¶
Index ¶
- Constants
- func NewStar(x int, y int, symbol rune, color string, speed float64) *matrix.Entity
- type Alien
- type Aliens
- func (a *Aliens) Create(x int, y int, offset int)
- func (a *Aliens) DoBulletCollision(bullet *matrix.Entity) (bool, int)
- func (a *Aliens) DoMove(w int, _ int)
- func (a *Aliens) Draw(surface interfaces.ISurface)
- func (a *Aliens) MakeAliens(aliensHorizontal int, x int, y int, rows int, cols int, reward int, offset int, ...) (int, int)
- func (a *Aliens) Setup(w int, h int)
- type Barricade
- type Bullet
- type Bullets
- type ByScore
- type Fragment
- type Fragments
- type GameState
- type HighScore
- type Invaders
- type Player
- func (player *Player) DecLives() bool
- func (player *Player) Draw(surface interfaces.ISurface)
- func (player *Player) GetLivesStr() string
- func (player *Player) HasCollision(e *matrix.Entity) bool
- func (player *Player) MoveLeft(minW int)
- func (player *Player) MoveRight(maxW int)
- func (player *Player) NewBullet()
- func (player *Player) WipeBullet()
- type Stars
Constants ¶
View Source
const ( FirstMenuItem = 0 Play int = iota - 1 Highscores Howto NumMenuItems )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Aliens ¶
type Aliens struct {
// contains filtered or unexported fields
}
func (*Aliens) DoBulletCollision ¶
func (*Aliens) Draw ¶
func (a *Aliens) Draw(surface interfaces.ISurface)
func (*Aliens) MakeAliens ¶
type Barricade ¶
type Barricade struct {
// contains filtered or unexported fields
}
func NewBarricade ¶
func NewBarricade() *Barricade
func (*Barricade) Draw ¶
func (b *Barricade) Draw(surface interfaces.ISurface)
type Bullets ¶
type Bullets struct {
// contains filtered or unexported fields
}
func NewBullets ¶
func NewBullets() *Bullets
func (*Bullets) Draw ¶
func (ab *Bullets) Draw(surface interfaces.ISurface)
type Fragments ¶
type Fragments struct {
// contains filtered or unexported fields
}
func NewFragments ¶
func NewFragments() *Fragments
func (*Fragments) AddFragment ¶
func (*Fragments) Draw ¶
func (f *Fragments) Draw(surface interfaces.ISurface)
type Invaders ¶
type Invaders struct {
// contains filtered or unexported fields
}
func (*Invaders) Draw ¶
func (g *Invaders) Draw(surface interfaces.ISurface)
func (*Invaders) SetMenuState ¶
func (g *Invaders) SetMenuState()
func (*Invaders) SetPlayState ¶
func (g *Invaders) SetPlayState()
type Player ¶
type Player struct {
// contains filtered or unexported fields
}
func (*Player) Draw ¶
func (player *Player) Draw(surface interfaces.ISurface)
func (*Player) GetLivesStr ¶
func (*Player) WipeBullet ¶
func (player *Player) WipeBullet()
Click to show internal directories.
Click to hide internal directories.