1
0
Fork 0

Move maze drawing into renderer package

This commit is contained in:
Henrik Hautakoski 2026-06-06 11:09:19 +02:00
parent dd37379bc5
commit c6b2a837b0
2 changed files with 17 additions and 10 deletions

15
game/renderer/maze.go Normal file
View file

@ -0,0 +1,15 @@
package renderer
import (
"pacman/engine/render"
"pacman/game/world"
)
// DrawMaze - draws the maze.
func DrawMaze(maze *world.Maze, x, y uint8) {
for tile_x := range uint8(world.MAZE_WIDTH) {
for tile_y := range uint8(world.MAZE_HEIGHT) {
render.DrawTile(x+tile_x, y+tile_y, maze.At(tile_x, tile_y))
}
}
}