save_menu#

Contains data related to Game Over / F6 / Save menus

Variables#

Functions#

int

Open()

void

GetName(char32[] buffer)

void

SetName(char32[] buffer)

void

RemoveOption(int index)

void

AddOption(int index = -1)

void

SwapOptions(int index_1, int index_2)

void

GetString(int index, char32[] buffer)

void

SetString(int index, char32[] buffer)

Enumerations#

enum SaveMenuFlags: πŸ”— Source

Used with save_menu::Flags[].

SaveMenuFlags SMENU_CONFIRM_A = 0

If checked, the A button can confirm, in addition to START.

SaveMenuFlags SMENU_CANCEL_B = 1

If checked, the B button can cancel. (Does not work on β€˜Game Over’ menu)

SaveMenuFlags SMENU_DONT_KILL_MUSIC = 2

If checked, the menu opening will not change the music. (save_menu::MIDI)

SaveMenuFlags SMENU_REPEAT_BG = 3

If checked, the save_menu::BGTile will be repated to fill the screen

SaveMenuFlags SMENU_DONT_KILL_SFX = 4

If checked, the menu opening will not stop SFX that are playing.


enum SaveMenuOptionFlags: πŸ”— Source

Used with save_menu::OptionFlags[].

SaveMenuOptionFlags SMENU_OPT_EXIT = 1

When this option is selected, the game will be exited to the save select. SMENU_OPT_RELOAD takes priority if set.

SaveMenuOptionFlags SMENU_OPT_CONTINUE = 2

When this option is selected, the player will β€˜Continue’ from their continue point. SMENU_OPT_RELOAD and SMENU_OPT_EXIT take priority if set.

SaveMenuOptionFlags SMENU_OPT_RELOAD = 4

When this option is selected, the game will be reloaded from the previous save.

SaveMenuOptionFlags SMENU_OPT_SAVE = 8

When this option is selected, the game will be saved.

SaveMenuOptionFlags SMENU_OPT_CANCEL = 16

When this option is selected, the save menu will close. (Does not work on β€˜Game Over’ menu)


Variable descriptions#

const int ID πŸ”— Source

Returns the ID of the menu.


int CursorTile πŸ”— Source

The tile used by this save menu for the cursor


int CursorCSet πŸ”— Source

The cset used by this save menu for the cursor


int BGColor πŸ”— Source

The color filling the background of the menu. Color 0 is NOT transparent here.


int BGTile πŸ”— Source

The upper-left tile used for the menu background. If 0, no tiles will be drawn (leaving only the BGColor)


int BGCSet πŸ”— Source

The cset the BGTile is drawn in.


int BGTileWidth πŸ”— Source

The number of tiles wide to draw the BGTile. Also see SMENU_REPEAT_BG.


int BGTileHeight πŸ”— Source

The number of tiles tall to draw the BGTile. Also see SMENU_REPEAT_BG.


int SFXCursor πŸ”— Source

The SFX played when moving the cursor.


int SFXChoose πŸ”— Source

The SFX played when choosing an option.


int HSpace πŸ”— Source

The space, in pixels, horizontally between the options and the cursor.


int VSpace πŸ”— Source

The space, in pixels, vertically between each option.


int X πŸ”— Source

The X value of the options.


int Y πŸ”— Source

The Y value of the first option


TextAlignment TextAlign πŸ”— Source

The alignment of the text within the textbox


TextAlignment TextBoxAlign πŸ”— Source

The alignment of the textbox relative to X


int CloseFrames πŸ”— Source

The duration, in frames, it takes to close the menu after an option is selected.


int CloseFlashRate πŸ”— Source

The rate, in frames, that the β€˜selected’ option blinks while the menu is closing.


int MIDI πŸ”— Source

The MIDI to play.


const int NumOptions πŸ”— Source

The number of options currently in the list.


bool[] Flags πŸ”— Source

index SaveMenuFlags (SMENU_)

The flags for the whole menu.


SaveMenuOptionFlags[] OptionFlags πŸ”— Source

The SaveMenuOptionFlags (SMENU_OPT_) for each option.


int[] Colors πŸ”— Source

The text colors for each option.


int[] PickedColors πŸ”— Source

The text colors for each option which are used when the option is selected.


int[] Fonts πŸ”— Source

The Font IDs for each option.


int[] FrozenScripts πŸ”— Source

The generic frozen script for each option.


Function descriptions#

int Open() πŸ”— Source

Runs the menu. Returns the selected index. If the menu is canceled via SMENU_CANCEL_B, returns -1.


void GetName(char32[] buffer) πŸ”— Source

Fills the buffer with the name of this save menu


void SetName(char32[] buffer) πŸ”— Source

Sets the name of this save menu to the buffer contents.


void RemoveOption(int index) πŸ”— Source

Deletes the option at index.


void AddOption(int index = -1) πŸ”— Source

Adds a new option at index. Negative index adds at the end.


void SwapOptions(int index_1, int index_2) πŸ”— Source

Swaps the options at index_1 and index_2.


void GetString(int index, char32[] buffer) πŸ”— Source

Fills the buffer with the string for option index


void SetString(int index, char32[] buffer) πŸ”— Source

Sets the string for option index to the contents of the buffer