mirror of
https://github.com/Fluffy-Bean/ColouringApp.git
synced 2025-05-28 14:23:10 +00:00
I actually just forgotten
This commit is contained in:
parent
1b05e0364b
commit
9225fd428a
6 changed files with 64 additions and 6 deletions
|
@ -9,10 +9,12 @@ import (
|
|||
|
||||
func Title() {
|
||||
var (
|
||||
titleText = "Example Game"
|
||||
)
|
||||
titleText = application.WindowTitle
|
||||
mapImage = raylib.LoadTexture(application.DirAssets + "Map.png")
|
||||
|
||||
// load resources here
|
||||
mapX = 0
|
||||
mapY = 0
|
||||
)
|
||||
|
||||
for !application.ShouldQuit {
|
||||
application.ShouldQuit = raylib.WindowShouldClose()
|
||||
|
@ -36,8 +38,26 @@ func Title() {
|
|||
application.ShouldQuit = true
|
||||
}
|
||||
|
||||
// Map thing?
|
||||
raylib.DrawRectangleLines(120, 39, application.WindowWidth-130, application.WindowHeight-49, raylib.White)
|
||||
raylib.BeginScissorMode(121, 40, application.WindowWidth-132, application.WindowHeight-51)
|
||||
|
||||
mapX += 1
|
||||
mapX = 0
|
||||
mapY = 0
|
||||
if mapX > 1920 {
|
||||
mapX = 0
|
||||
}
|
||||
|
||||
mapY += 1
|
||||
if mapY > 1080 {
|
||||
mapY = 0
|
||||
}
|
||||
raylib.DrawTexture(mapImage, int32(-mapX), int32(-mapY), raylib.White)
|
||||
|
||||
raylib.EndScissorMode()
|
||||
raylib.EndDrawing()
|
||||
}
|
||||
|
||||
// unload resources here
|
||||
raylib.UnloadTexture(mapImage)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue