ColouringApp/scenes/playerData.go

40 lines
786 B
Go
Raw Normal View History

2024-01-11 00:17:29 +00:00
package scenes
import (
"ColouringApp/application"
"os"
2024-01-11 00:17:29 +00:00
raylib "github.com/gen2brain/raylib-go/raylib"
)
func PlayerData() {
// Load player data here
for !application.ShouldQuit {
// DEFAULT
{
application.ShouldQuit = raylib.WindowShouldClose()
if application.CurrentScene != application.ScenePlayerData {
break
}
2024-01-11 00:17:29 +00:00
}
// check if userData exists
if _, err := os.Stat(application.DirUserData); os.IsNotExist(err) {
err := os.Mkdir(application.DirUserData, 0755)
if err != nil {
panic(err)
}
}
2024-01-11 00:17:29 +00:00
// DRAW
{
raylib.BeginDrawing()
raylib.ClearBackground(raylib.Black)
raylib.DrawText("Loading...", 10, application.WindowHeight-30, 20, raylib.White)
raylib.EndDrawing()
}
2024-01-23 15:33:29 +00:00
2024-01-11 00:17:29 +00:00
application.CurrentScene = application.SceneTitle
}
}