Walking
This commit is contained in:
6
main.go
6
main.go
@@ -45,6 +45,7 @@ type Game struct {
|
||||
}
|
||||
|
||||
func (g *Game) Update() error {
|
||||
g.terrain.GoDown()
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -63,8 +64,9 @@ var GameInstance *Game
|
||||
func init() {
|
||||
|
||||
GameInstance = &Game{}
|
||||
GameInstance.hero = &hero.Hero{}
|
||||
GameInstance.terrain = &terrain.Terrain{}
|
||||
GameInstance.hero = hero.NewHero()
|
||||
GameInstance.terrain = terrain.NewTerrain()
|
||||
GameInstance.hero.Walk()
|
||||
}
|
||||
|
||||
func main() {
|
||||
|
||||
Reference in New Issue
Block a user