Getting Started
Welcome to the ratr0-engine documentation.
Initialization
Before doing anything else, you must initialize the global engine state.
-
Ratr0Engine *ratr0_engine_startup(struct Ratr0MemoryConfig *memory_config, int argc, char **argv)
Startup the engine and all its subsystems.
- Parameters:
memory_config – memory configuration
argc – number of command line arguments
argv – command line arguments
- Returns:
pointer to the initialized engine system
Configuration Options
The engine setup is controlled by the following structure:
-
struct Ratr0MemoryConfig
Pre-allocate memory at the start of the game. This ensures we never explicitly allocate or deallocate memory outside of the engine.
Public Members
-
UINT32 general_pool_size
pool size in bytes
-
UINT32 general_table_size
num entries in table
-
UINT32 chip_pool_size
pool size in bytes
-
UINT32 chip_table_size
num entries in table
-
UINT32 general_pool_size
Tip
Always check the return value of the init function. If it returns a non-zero value, check your graphics drivers.