Skip to content

Commit 3ec6536

Browse files
committed
menu background image
1 parent 1ecad54 commit 3ec6536

File tree

3 files changed

+618
-4
lines changed

3 files changed

+618
-4
lines changed

CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ set(SRC_FILES
2828
${SRC_DIR}/boot.S
2929
${SRC_DIR}/def.c
3030
${SRC_DIR}/font.c
31-
${SRC_DIR}/math.c
31+
${SRC_DIR}/maze.c
3232
${SRC_DIR}/framebf.c
3333
${SRC_DIR}/image.c
3434
${SRC_DIR}/game_be.c

kernel/game_be.c

+3-3
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
#include "../lib/data/game/player.h"
1111
#include "../lib/data/game/item.h"
1212
#include "../lib/data/game/player_movement.h"
13+
#include "lib/data/data_menu_background.h"
1314

1415
// ===== BACK-END =====
1516
const char directionKey[] = {'w', 'a', 's', 'd'};
@@ -20,11 +21,10 @@ void game_enter() {
2021
// init
2122
framebf_init(GAME_W, GAME_H, GAME_W, GAME_H);
2223

23-
// background + headline
24-
clearScreen();
24+
framebf_drawImg(0, 0, MENU_BACKGROUND_SIZE, MENU_BACKGROUND_SIZE, bitmap_menu_background);
2525

2626
// menu
27-
int menuPosX = 150, menuPosY = 200, yOffset = 50;
27+
int menuPosX = 220, menuPosY = 250, yOffset = 50;
2828
char *opts[] = {"Start", "Continue", "How To Play?", "Exit"};
2929
int optSz = sizeof(opts) / sizeof(opts[0]);
3030

0 commit comments

Comments
 (0)