diff options
| -rw-r--r-- | assets/death_menu_art.xcf | bin | 0 -> 235624 bytes | |||
| -rw-r--r-- | assets/floor.png | bin | 147486 -> 152741 bytes | |||
| -rw-r--r-- | assets/main_menu.png | bin | 0 -> 76793 bytes | |||
| -rw-r--r-- | assets/menu_art.xcf | bin | 0 -> 250713 bytes | |||
| -rw-r--r-- | assets/restart_menu.png | bin | 0 -> 76251 bytes | |||
| -rw-r--r-- | src/menu.c | 20 |
6 files changed, 17 insertions, 3 deletions
diff --git a/assets/death_menu_art.xcf b/assets/death_menu_art.xcf Binary files differnew file mode 100644 index 0000000..3e485c5 --- /dev/null +++ b/assets/death_menu_art.xcf diff --git a/assets/floor.png b/assets/floor.png Binary files differindex e400264..83c8d4c 100644 --- a/assets/floor.png +++ b/assets/floor.png diff --git a/assets/main_menu.png b/assets/main_menu.png Binary files differnew file mode 100644 index 0000000..d2abc52 --- /dev/null +++ b/assets/main_menu.png diff --git a/assets/menu_art.xcf b/assets/menu_art.xcf Binary files differnew file mode 100644 index 0000000..63d49b7 --- /dev/null +++ b/assets/menu_art.xcf diff --git a/assets/restart_menu.png b/assets/restart_menu.png Binary files differnew file mode 100644 index 0000000..1b451bc --- /dev/null +++ b/assets/restart_menu.png @@ -15,10 +15,10 @@ void init_menu(void) { splash_texture = rodeo_texture_2d_create_from_path(cstr_lit("assets/splash.png")); - main_menu_texture = rodeo_texture_2d_create_from_path(cstr_lit("assets/mainmenu.png")); - gameover_texture = rodeo_texture_2d_create_from_path(cstr_lit("assets/gameover.png")); + main_menu_texture = rodeo_texture_2d_create_from_path(cstr_lit("assets/main_menu.png")); + gameover_texture = rodeo_texture_2d_create_from_path(cstr_lit("assets/restart_menu.png")); - menu_state = menu_state_splash; + menu_state = menu_state_main; splash_timer = 3000.0f; rodeo_input_scene_activate(get_command_inputs()->menu_scene); } @@ -34,6 +34,7 @@ deinit_menu(void) void draw_menu(void) { + float transparency = 0.65f; if (splash_timer > 0 && menu_state == menu_state_splash) { splash_timer -= rodeo_frame_time_get(); @@ -49,6 +50,13 @@ draw_menu(void) } else if (menu_state == menu_state_main) { + + rodeo_texture_2d_draw( + &screen_dimensions, + &screen_dimensions, + &(rodeo_color_RGBAFloat_t){ .array = { 0,0,0,transparency }}, + NULL + ); rodeo_texture_2d_draw( &screen_dimensions, &screen_dimensions, @@ -61,6 +69,12 @@ draw_menu(void) rodeo_texture_2d_draw( &screen_dimensions, &screen_dimensions, + &(rodeo_color_RGBAFloat_t){ .array = { 0,0,0,transparency }}, + NULL + ); + rodeo_texture_2d_draw( + &screen_dimensions, + &screen_dimensions, NULL, &gameover_texture ); |
