Fixed humans winning on round end when no humans present, removed classes file cvar and made it use the config module, replaced SetFailState with LogMessageFormatted with fail flag, made the base config manipulator function.
This commit is contained in:
@ -24,45 +24,6 @@ new dxLevel[MAXPLAYERS + 1];
|
||||
*/
|
||||
new bool:g_bZombieSpawned;
|
||||
|
||||
/**
|
||||
* Converts string of "yes" or "no" to a boolean value.
|
||||
*
|
||||
* @param option "yes" or "no" string to be converted.
|
||||
* @return True if string is "yes", false otherwise.
|
||||
*/
|
||||
bool:ZRConfigSettingToBool(const String:option[])
|
||||
{
|
||||
// If option is equal to "yes," then return true.
|
||||
if (StrEqual(option, "yes", false))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
// Option isn't "yes."
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts boolean value to "yes" or "no".
|
||||
*
|
||||
* @param bOption True/false value to be converted to "yes"/"no", respectively.
|
||||
* @param option Variable to store "yes" or "no" in.
|
||||
* @param maxlen Max length of return string, (can't be more than 4)
|
||||
*/
|
||||
ZRBoolToConfigSetting(bool:bOption, String:option[], maxlen)
|
||||
{
|
||||
// If option is true, then copy "yes" to return string.
|
||||
if (bOption)
|
||||
{
|
||||
strcopy(option, maxlen, "yes");
|
||||
}
|
||||
// If option is false, then copy "no" to return string.
|
||||
else
|
||||
{
|
||||
strcopy(option, maxlen, "no");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Create an array populated with eligible clients to be zombie.
|
||||
*
|
||||
|
Reference in New Issue
Block a user