class
FLevelGrammar
The whole generator configuration, one .levelgrammar MDF asset: the starting chain, the rules, the module catalogue and the validation budget.
- Module
- LevelGen
- Header
#include "LevelGen/LevelGrammar.h"- Namespace
Mowo
Properties
| Type | Name | Description |
|---|---|---|
std::vector<std::string> | StartChain | |
std::string | StartType | Default "Start". |
std::string | GoalType | Default "Goal". |
std::vector<FLevelRule> | Rules | |
std::vector<FLevelModuleDef> | Modules | |
std::vector<FLevelTypeLimit> | Limits | |
int32_t | MaxRewriteSteps | Default 48. |
int32_t | MaxNodes | Default 32. |
int32_t | MaxAttempts | Default 24. |
float | CellSize | Default 4.0f. |
float | MinDoorWidth | Default 1.6f. |
int32_t | MinCriticalPath | Default 4. |
int32_t | MaxCriticalPath | Default 16. |
int32_t | MaxPortalDepth | Default 3. |
int32_t | MaxScanCost | Default 40000. |
int32_t | MaxRoomScanCost | Default 4000. |
std::string | CapPrefab | Placed on every socket nothing connected to, and on every edge where two modules touch without a doorway (so the level never shows two coplanar walls back to back). |
std::string | SharedWallPrefab |
Public functions
| Returns | Name | Description |
|---|---|---|
int32_t | FindModule | |
std::string | SerializeToString | |
bool | LoadFromString | |
bool | LoadFromFile | |
bool | SaveToFile | |
FLevelGrammar | CreateDefault | AJAX's facility: fifteen rules over entrance, corridors, hubs, labs, storage, offices, maintenance, stairs, dead ends and the objective. |
const char* | SideName | |
ELevelSide | SideFromName | |
const char* | RuleKindName | |
ELevelRuleKind | RuleKindFromName |
Function details
FindModule
C++
int32_t FindModule(const std::string& name) constSerializeToString
C++
std::string SerializeToString() constLoadFromString
C++
bool LoadFromString(const std::string& text)LoadFromFile
C++
bool LoadFromFile(const std::string& path)SaveToFile
C++
bool SaveToFile(const std::string& path) constCreateDefault
C++
static FLevelGrammar CreateDefault()AJAX's facility: fifteen rules over entrance, corridors, hubs, labs, storage, offices, maintenance, stairs, dead ends and the objective.
SideName
C++
static const char* SideName(ELevelSide side)SideFromName
C++
static ELevelSide SideFromName(const std::string& name)RuleKindName
C++
static const char* RuleKindName(ELevelRuleKind kind)RuleKindFromName
C++
static ELevelRuleKind RuleKindFromName(const std::string& name)Generated from LevelGen/LevelGrammar.h via levelgen.json · Oct 26, 2026Version 1.0.0