mirror of
https://github.com/s1lentq/ReGameDLL_CS.git
synced 2025-01-13 23:28:04 +03:00
Added new cvar bot_join_delay
This commit is contained in:
parent
ad57e0abc1
commit
555b08faa6
@ -47,6 +47,7 @@ Archive's bin directory contains 2 subdirectories, 'bugfixed' and 'pure'
|
||||
| sv_alltalk | 0 | 0 | 4 | When players can hear each other ([further explanation](../../wiki/sv_alltalk)).<br/>`0` dead don't hear alive<br/>`1` no restrictions<br/>`2` teammates hear each other<br/>`3` Same as 2, but spectators hear everybody<br/>`4` alive hear alive, dead hear dead and alive.
|
||||
| bot_deathmatch | 0 | 0 | 1 | Set's the mode for the zBot.<br/>`0` disabled<br/>`1` enable mode Deathmatch and not allow to do the scenario |
|
||||
| bot_quota_mode | normal | - | - | Determines the type of quota.<br/>`normal` default behaviour<br/>`fill` the server will adjust bots to keep `N` players in the game, where `N` is bot_quota<br/>`match` the server will maintain a `1:N` ratio of humans to bots, where `N` is bot_quota |
|
||||
| bot_join_delay | 0 | - | - | Prevents bots from joining the server for this many seconds after a map change. |
|
||||
| mp_item_staytime | 300 | - | - | Time to remove item that have been dropped from the players. |
|
||||
| mp_legacy_bombtarget_touch | 1 | 0 | 1 | Legacy func_bomb_target touch. New one is more strict. <br/>`0` New behavior<br/>`1` Legacy behavior|
|
||||
| mp_respawn_immunitytime | 0 | 0 | - | Specifies the players defense time after respawn. (in seconds).<br/>`0` disabled<br/>`>0.00001` time delay to remove protection |
|
||||
|
5
dist/game.cfg
vendored
5
dist/game.cfg
vendored
@ -166,6 +166,11 @@ bot_deathmatch 0
|
||||
// Default value: "normal"
|
||||
bot_quota_mode "normal"
|
||||
|
||||
// Prevents bots from joining the server for this many seconds after a map change.
|
||||
//
|
||||
// Default value: "0"
|
||||
bot_join_delay 0
|
||||
|
||||
// Debug cvar shows triggers.
|
||||
// 0 - disabled (default behaviour)
|
||||
// 1 - enabled
|
||||
|
@ -60,6 +60,7 @@ cvar_t cv_bot_profile_db = { "bot_profile_db", "BotProfile.db", FCVA
|
||||
#ifdef REGAMEDLL_ADD
|
||||
cvar_t cv_bot_deathmatch = { "bot_deathmatch", "0", FCVAR_SERVER, 0.0f, nullptr };
|
||||
cvar_t cv_bot_quota_mode = { "bot_quota_mode", "normal", FCVAR_SERVER, 0.0f, nullptr };
|
||||
cvar_t cv_bot_join_delay = { "bot_join_delay", "0", FCVAR_SERVER, 0.0f, nullptr };
|
||||
#else
|
||||
// Migrated to bot_quota_mode, use "match"
|
||||
cvar_t cv_bot_quota_match = { "bot_quota_match", "0", FCVAR_SERVER, 0.0f, nullptr };
|
||||
@ -127,6 +128,7 @@ void Bot_RegisterCVars()
|
||||
#ifdef REGAMEDLL_ADD
|
||||
CVAR_REGISTER(&cv_bot_deathmatch);
|
||||
CVAR_REGISTER(&cv_bot_quota_mode);
|
||||
CVAR_REGISTER(&cv_bot_join_delay);
|
||||
#endif
|
||||
|
||||
}
|
||||
|
@ -60,6 +60,7 @@ extern cvar_t cv_bot_profile_db;
|
||||
#ifdef REGAMEDLL_ADD
|
||||
extern cvar_t cv_bot_deathmatch;
|
||||
extern cvar_t cv_bot_quota_mode;
|
||||
extern cvar_t cv_bot_join_delay;
|
||||
#else
|
||||
extern cvar_t cv_bot_quota_match;
|
||||
#endif
|
||||
|
@ -875,6 +875,15 @@ void CCSBotManager::MaintainBotQuota()
|
||||
desiredBotCount = 0;
|
||||
}
|
||||
|
||||
#ifdef REGAMEDLL_ADD
|
||||
// wait until the map has been loaded for a bit, to allow players to transition across
|
||||
// the transition without missing the pistol round
|
||||
if (static_cast<int>(cv_bot_join_delay.value) > CSGameRules()->GetMapElapsedTime())
|
||||
{
|
||||
desiredBotCount = 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
// if bots will auto-vacate, we need to keep one slot open to allow players to join
|
||||
if (cv_bot_auto_vacate.value > 0.0)
|
||||
desiredBotCount = Q_min(desiredBotCount, gpGlobals->maxClients - (totalHumansInGame + 1));
|
||||
|
@ -635,6 +635,7 @@ public:
|
||||
float GetRoundRemainingTimeReal() const;
|
||||
float GetTimeLeft() const { return m_flTimeLimit - gpGlobals->time; }
|
||||
float GetRoundElapsedTime() const { return gpGlobals->time - m_fRoundStartTime; }
|
||||
float GetMapElapsedTime() const { return gpGlobals->time; }
|
||||
|
||||
BOOL TeamFull(int team_id);
|
||||
BOOL TeamStacked(int newTeam_id, int curTeam_id);
|
||||
|
Loading…
x
Reference in New Issue
Block a user