Blamite Game Engine - blam!  00263.10.17.20.0001.blamite
The core library for the Blamite Game Engine.
Classes | Enumerations | Functions
Blam::DebugMenu Namespace Reference

Namespace containing data for the engine's debug menu. More...

Classes

struct  Menu
 Structure containing data for the root of the debug menu. More...
 
class  MenuItem
 Class used to store data and functions relating to an item within the engine's debug menu. More...
 

Enumerations

enum  MenuItemType {
  Executor, ExecSequence, Global, Submenu,
  Unknown
}
 Menu item type enumerator. More...
 

Functions

BLAM void InitializeDebugMenu ()
 Initializes the debug menu. More...
 
BLAM void ReloadDebugMenu ()
 Clears all existing data for the debug menu and reloads it from the file. More...
 
BLAM Menu GetDebugMenu ()
 Retrieves the debug menu data. More...
 

Detailed Description

Namespace containing data for the engine's debug menu.

Enumeration Type Documentation

◆ MenuItemType

Menu item type enumerator.

Enumerator
Executor 

Runs a console command upon activation.

ExecSequence 

Runs a sequence of console commands upon activation.

One command is run per activation. After initial activation, the second activation will run the second command in the sequence. Upon reaching the end of the sequence, the next activation will run the command at the start of the sequence.

Global 

Modifies an engine global upon activation.

Submenu 

Enters into a submenu/subscreen upon activation.

Unknown 

Fallback in the event that debug_menu_init contained an invalid option.

Function Documentation

◆ GetDebugMenu()

Blam::DebugMenu::Menu Blam::DebugMenu::GetDebugMenu ( )

Retrieves the debug menu data.

Returns
- gee i fuckin wonder, what do you think

◆ InitializeDebugMenu()

void Blam::DebugMenu::InitializeDebugMenu ( )

Initializes the debug menu.

This function will try and load a file with the .xml extension first. If that isn't found, it will attempt to load a file with the .txt extension as an XML file as a fallback. Ideally, we would have proper support for the original debug menu file format - and it probably wouldn't be that hard, really. The original debug menu is almost XML, but has a few key points where it breaks away from the standard.

As a result, virtually any attempt to load a legacy debug_menu_init.txt will fail. Hopefully at some point, we can build a proper interpreter to load those old files again.

◆ ReloadDebugMenu()

void Blam::DebugMenu::ReloadDebugMenu ( )

Clears all existing data for the debug menu and reloads it from the file.