mirror of
https://github.com/alliedmodders/amxmodx.git
synced 2024-12-24 13:55:36 +03:00
Fix few issues.
This commit is contained in:
parent
b97093a778
commit
2d07189e38
@ -101,7 +101,7 @@ public:
|
||||
bool ReadINI_NewSection(const char *section, bool invalid_tokens, bool close_bracket, bool extra_tokens, unsigned int *curtok)
|
||||
{
|
||||
if (new_section != -1)
|
||||
return executeForwards(new_section, handle, section, invalid_tokens, close_bracket, extra_tokens, *curtok) > 0 ? false : true;
|
||||
return executeForwards(new_section, handle, section, invalid_tokens, close_bracket, extra_tokens, *curtok) > 0 ? true : false;
|
||||
|
||||
return true;
|
||||
}
|
||||
@ -109,7 +109,7 @@ public:
|
||||
bool ReadINI_KeyValue(const char *key, const char *value, bool invalid_tokens, bool equal_token, bool quotes, unsigned int *curtok)
|
||||
{
|
||||
if (key_value != -1)
|
||||
return executeForwards(key_value, handle, key, value, invalid_tokens, equal_token, quotes, *curtok) > 0 ? false : true;
|
||||
return executeForwards(key_value, handle, key, value, invalid_tokens, equal_token, quotes, *curtok) > 0 ? true : false;
|
||||
|
||||
return true;
|
||||
}
|
||||
@ -117,7 +117,7 @@ public:
|
||||
bool ReadINI_RawLine(const char *line, unsigned int *curtok)
|
||||
{
|
||||
if (raw_line != -1)
|
||||
return executeForwards(raw_line, handle, line, *curtok) > 0 ? false : true;
|
||||
return executeForwards(raw_line, handle, line, *curtok) > 0 ? true : false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@ -212,33 +212,38 @@ public ReadCSDM_NewSection(INIParser:handle, const section[], bool:invalid_token
|
||||
if ((equal(section, "secondary") && !extra_tokens) ||
|
||||
(equal(section, "botsecondary") && close_bracket))
|
||||
{
|
||||
return;
|
||||
return true;
|
||||
}
|
||||
|
||||
++SuccessCount;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
public ReadCSDM_KeyValue(INIParser:handle, const key[], const value[], bool:invalid_tokens, bool:equal_token, bool:quotes, curtok)
|
||||
public bool:ReadCSDM_KeyValue(INIParser:handle, const key[], const value[], bool:invalid_tokens, bool:equal_token, bool:quotes, curtok)
|
||||
{
|
||||
Debug && server_print("^t^tReadCSDM_KeyValue - %-32s %s", key, value);
|
||||
|
||||
new buffer[128];
|
||||
if (TrieGetString(ExpectedKVData, key, buffer, charsmax(buffer)) && equal(value, buffer))
|
||||
{
|
||||
if (equal(value, "colors") && !quotes)
|
||||
if (equal(key, "colors") && !quotes)
|
||||
{
|
||||
return;
|
||||
return true;
|
||||
}
|
||||
|
||||
++SuccessCount;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
public ReadCSDM_CurrentLine(INIParser:handle, const line[], curtok)
|
||||
public bool:ReadCSDM_CurrentLine(INIParser:handle, const line[], curtok)
|
||||
{
|
||||
//Debug && server_print("^t^tReadCSDM_CurrentLine - %s", line);
|
||||
++SuccessCount;
|
||||
return true;
|
||||
}
|
||||
|
||||
public ReadCSDM_ParseEnd(INIParser:handle, bool:halted, bool:failed)
|
||||
|
Loading…
Reference in New Issue
Block a user