diff --git a/README.md b/README.md index b06d1b5..1d469d9 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,8 @@ # autogo -The silly Raylib cargame I made in C but in Go +The silly Raylib cargame I made in C but in Go for my champ + +## Screenshot +![Screenshot](./resources/screenshot.png) ### note Garage texture diff --git a/main.go b/main.go index 7418bc8..d5edd38 100644 --- a/main.go +++ b/main.go @@ -90,11 +90,9 @@ func (g *Game) draw() { // Draw car rl.DrawTexture(g.car.texture, int32(g.car.xPos), int32(g.car.lane*laneHeight), g.car.color) - // Display score or game over + rl.DrawText(fmt.Sprintf("Score: %d\nHigh Score: %d", g.score, highScore), 10, 10, 32, rl.DarkGreen) if g.gameOver { rl.DrawText("You're not an WinRAR :(\nPress Enter to Restart", int32(screenWidth/2-150), int32(screenHeight/2-20), 32, rl.Red) - } else { - rl.DrawText(fmt.Sprintf("Score: %d\nHigh Score: %d", g.score, highScore), 10, 10, 32, rl.DarkGreen) } } diff --git a/resources/screenshot.png b/resources/screenshot.png new file mode 100644 index 0000000..71b6519 Binary files /dev/null and b/resources/screenshot.png differ