use etxt for debug printing

This commit is contained in:
2024-05-28 13:37:32 +02:00
parent 80ef96ceb7
commit 106ff1970a
4 changed files with 36 additions and 7 deletions

View File

@@ -1,12 +1,15 @@
package main
import "github.com/hajimehoshi/ebiten/v2"
import (
"github.com/hajimehoshi/ebiten/v2"
)
type Game struct {
ScreenWidth, ScreenHeight, Cellsize int
Scenes map[SceneName]Scene
CurrentScene SceneName
Config *Config
Scale int
}
func NewGame(config *Config, startscene SceneName) *Game {
@@ -34,6 +37,7 @@ func (game *Game) GetCurrentScene() Scene {
}
func (game *Game) Layout(outsideWidth, outsideHeight int) (int, int) {
game.Scale = outsideWidth / 100
return game.ScreenWidth, game.ScreenHeight
}