Swadge 2024 2.0.0
APIs to develop games for the Magfest Swadge
|
This file simplifies adding your mode to the emulator, main menu, and other systems that require knowledge of multiple modes.
To add a new mode, simply add #include "your_mode_name.h"
to the bottom of the includes list in modeIncludesList.h before going to modeIncludeList.c and performing the following two actions:
&
.addSingleItemToMenu(menu, yourMode.modeName);
line in the appropriate section of modeListSetMenu()Currently, there's three categories: Games, Music, and Utilities. Add a new mode to the correct section of the modeListSetMenu() to avoid causing confusion.
Devs can also get the count of mode via the modeListGetCount() function, which just returns the count of items in the allSwadgeModes array.
Go to the source code of this file.
Functions | |
int | modeListGetCount (void) |
Gets the current number of swadgeModes present int he file. | |
void | modeListSetMenu (menu_t *menu) |
Iniitalizes a menu with all the current swadge modes. | |
Variables | |
swadgeMode_t *const | allSwadgeModes [] |
Add swadgeMode_t pointers to this struct to include them in emulator and main menu. | |
int modeListGetCount | ( | void | ) |
Gets the current number of swadgeModes present int he file.
void modeListSetMenu | ( | menu_t * | menu | ) |
Iniitalizes a menu with all the current swadge modes.
menu | Menu to set |
|
extern |
Add swadgeMode_t pointers to this struct to include them in emulator and main menu.