tresinformal / drakkar

The tresinformal video game called 'Drakkar'
GNU General Public License v3.0
11 stars 4 forks source link

Add an "Options" button to the menu #446

Closed TheoPannetier closed 2 years ago

TheoPannetier commented 2 years ago

Currently, the menu shows three buttons: action, about and quit.

game_menu

There is no way to access the options screen (i.e, options_view) from the menu. Add a fourth button options button to the menu, that will (later) lead to the options screen. The button should be located between "action" and "about".

Choose a colour for it, and feel free to also change the colours of the other buttons, and the menu background if you're feeling creative 🎨

#define FIX_ISSUE_446
  #ifdef FIX_ISSUE_446
  // Add an "Options" button to the menu
  {
     menu m;
     assert(m.get_buttons().size() == 4);
     assert(m.get_button(1).get_name() == "options");
  }
  #endif // FIX_ISSUE_446
TheoPannetier commented 2 years ago

Done 😎