diff --git a/cfg/addons/yapb/conf/custom.cfg b/cfg/addons/yapb/conf/custom.cfg index 483d9c6..5b42838 100644 --- a/cfg/addons/yapb/conf/custom.cfg +++ b/cfg/addons/yapb/conf/custom.cfg @@ -69,3 +69,9 @@ EnableFakeBotFeatures = no ; sent to the server console. This replaces yb_logger_disable_logfile cvar. ; DisableLogFile = no + +; +; Disables enforcement of player spawn limits during bot creation and quota management, +; allowing the use of custom spawn editors. +; +DisableSpawnControl = no diff --git a/src/config.cpp b/src/config.cpp index 873ccfd..8fe9a1f 100644 --- a/src/config.cpp +++ b/src/config.cpp @@ -730,7 +730,8 @@ void BotConfig::loadCustomConfig () { { "ZMInfectedTeam", "T" }, { "EnableFakeBotFeatures", "no" }, { "DisableLogFile", "no" }, - { "CheckConnectivityHost", "yapb.jeefo.net" } + { "CheckConnectivityHost", "yapb.jeefo.net" }, + { "DisableSpawnControl", "no" } }; }; setDefaults (); diff --git a/src/manager.cpp b/src/manager.cpp index 862661e..fef1a37 100644 --- a/src/manager.cpp +++ b/src/manager.cpp @@ -448,6 +448,11 @@ void BotManager::maintainQuota () { maxSpawnCount = maxClients + 1; } + // disable spawn control + if (conf.fetchCustom ("DisableSpawnControl").startsWith ("yes")) { + maxSpawnCount = game.maxClients () + 1; + } + // sent message only to console from here ctrl.setFromConsole (true);