Allow arbitrary indentation on the BMS loader.
This commit is contained in:
@@ -404,9 +404,17 @@ struct bmsCommandTree
|
|||||||
{
|
{
|
||||||
line++;
|
line++;
|
||||||
|
|
||||||
if (statement.length() == 0 || statement[0] != '#') // Skip.
|
if (statement.length() == 0) // Skip.
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
// LTrim the statement to allow indentation
|
||||||
|
size_t hash = statement.find('#');
|
||||||
|
|
||||||
|
if (hash == RString::npos)
|
||||||
|
return;
|
||||||
|
|
||||||
|
statement = statement.substr(hash);
|
||||||
|
|
||||||
size_t space = statement.find(' ');
|
size_t space = statement.find(' ');
|
||||||
RString name = statement.substr(0, space);
|
RString name = statement.substr(0, space);
|
||||||
RString value = "";
|
RString value = "";
|
||||||
|
|||||||
Reference in New Issue
Block a user