|
| CLevelParser () |
| Create an empty level file.
|
|
| CLevelParser (std::string filename) |
| Load level from file.
|
|
| CLevelParser (LevelCategory category, int chapter, int rank) |
| Load given level.
|
|
| CLevelParser (std::string category, int chapter, int rank) |
|
bool | Exists () |
| Check if level file exists.
|
|
void | Load () |
| Load file.
|
|
void | Save () |
| Save file.
|
|
void | SetLevelPaths (LevelCategory category, int chapter=0, int rank=0) |
| Configure level paths for the given level.
|
|
std::string | InjectLevelPaths (const std::string &path, const std::string &defaultDir="") |
| Inject something% paths.
|
|
const std::string & | GetFilename () |
| Get filename.
|
|
const std::vector< CLevelParserLineUPtr > & | GetLines () |
| Get all lines from file.
|
|
void | AddLine (CLevelParserLineUPtr line) |
| Insert new line to file.
|
|
CLevelParserLine * | Get (const std::string &command) |
| Find first line with given command.
|
|
CLevelParserLine * | GetIfDefined (const std::string &command) |
| Find first line with given command, null if doesn't exist.
|
|
int | CountLines (const std::string &command) |
| Count lines with given command.
|
|
|
static std::string | BuildCategoryPath (LevelCategory category) |
| Build category path.
|
|
static std::string | BuildCategoryPath (std::string category) |
|
static std::string | BuildScenePath (LevelCategory category, int chapter, int rank, bool sceneFile=true) |
| Build level filename.
|
|
static std::string | BuildScenePath (std::string category, int chapter, int rank, bool sceneFile=true) |
|
◆ CLevelParser() [1/3]
CLevelParser::CLevelParser |
( |
| ) |
|
Create an empty level file.
◆ CLevelParser() [2/3]
CLevelParser::CLevelParser |
( |
std::string |
filename | ) |
|
◆ CLevelParser() [3/3]
CLevelParser::CLevelParser |
( |
LevelCategory |
category, |
|
|
int |
chapter, |
|
|
int |
rank |
|
) |
| |
◆ BuildCategoryPath()
std::string CLevelParser::BuildCategoryPath |
( |
LevelCategory |
category | ) |
|
|
static |
◆ BuildScenePath()
std::string CLevelParser::BuildScenePath |
( |
LevelCategory |
category, |
|
|
int |
chapter, |
|
|
int |
rank, |
|
|
bool |
sceneFile = true |
|
) |
| |
|
static |
◆ Exists()
bool CLevelParser::Exists |
( |
| ) |
|
Check if level file exists.
◆ Load()
void CLevelParser::Load |
( |
| ) |
|
◆ Save()
void CLevelParser::Save |
( |
| ) |
|
◆ SetLevelPaths()
void CLevelParser::SetLevelPaths |
( |
LevelCategory |
category, |
|
|
int |
chapter = 0 , |
|
|
int |
rank = 0 |
|
) |
| |
Configure level paths for the given level.
◆ InjectLevelPaths()
std::string CLevelParser::InjectLevelPaths |
( |
const std::string & |
path, |
|
|
const std::string & |
defaultDir = "" |
|
) |
| |
◆ GetFilename()
const std::string & CLevelParser::GetFilename |
( |
| ) |
|
◆ GetLines()
const std::vector< CLevelParserLineUPtr > & CLevelParser::GetLines |
( |
| ) |
|
|
inline |
◆ AddLine()
void CLevelParser::AddLine |
( |
CLevelParserLineUPtr |
line | ) |
|
◆ Get()
Find first line with given command.
◆ GetIfDefined()
Find first line with given command, null if doesn't exist.
◆ CountLines()
int CLevelParser::CountLines |
( |
const std::string & |
command | ) |
|
Count lines with given command.
The documentation for this class was generated from the following files:
- src/level/parser/parser.h
- src/level/parser/parser.cpp