From: bones_was_here Date: Sun, 2 May 2021 15:47:29 +0000 (+1000) Subject: Rename sv_maxidle_spectatorsareidle to sv_maxidle_alsokickspectators, enable by defau... X-Git-Tag: xonotic-v0.8.5~419^2~2 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=31fffef7c14a75a2b2b39835686b17fdeea6515b;p=xonotic%2Fxonotic-data.pk3dir.git Rename sv_maxidle_spectatorsareidle to sv_maxidle_alsokickspectators, enable by default and further clarify desc If it's not enabled, enabling sv_maxidle will have no effect when sv_maxidle_playertospectator is enabled --- diff --git a/qcsrc/server/client.qc b/qcsrc/server/client.qc index e988d4bdc..01426367a 100644 --- a/qcsrc/server/client.qc +++ b/qcsrc/server/client.qc @@ -2701,7 +2701,7 @@ void PlayerPostThink (entity this) if (autocvar_sv_maxidle > 0 || (IS_PLAYER(this) && autocvar_sv_maxidle_playertospectator > 0)) if (frametime) // WORKAROUND: only use dropclient in server frames (frametime set). Never use it in cl_movement frames (frametime zero). if (IS_REAL_CLIENT(this)) - if (IS_PLAYER(this) || autocvar_sv_maxidle_spectatorsareidle) + if (IS_PLAYER(this) || autocvar_sv_maxidle_alsokickspectators) if (!intermission_running) // NextLevel() kills all centerprints after setting this true { int totalClients = 0; diff --git a/qcsrc/server/client.qh b/qcsrc/server/client.qh index ed3273be8..1197ee361 100644 --- a/qcsrc/server/client.qh +++ b/qcsrc/server/client.qh @@ -34,7 +34,7 @@ string autocvar_g_mutatormsg; float autocvar_sv_foginterval; float autocvar_sv_maxidle; float autocvar_sv_maxidle_playertospectator; -bool autocvar_sv_maxidle_spectatorsareidle; +bool autocvar_sv_maxidle_alsokickspectators; int autocvar_sv_maxidle_slots; bool autocvar_sv_maxidle_slots_countbots; bool autocvar_g_forced_respawn; diff --git a/xonotic-server.cfg b/xonotic-server.cfg index de85a58ee..7b7fb72eb 100644 --- a/xonotic-server.cfg +++ b/xonotic-server.cfg @@ -412,7 +412,7 @@ sv_gameplayfix_droptofloorstartsolid 0 set sv_foginterval 1 "force enable fog in regular intervals" set sv_maxidle 0 "kick players idle for more than this amount of time in seconds" -set sv_maxidle_spectatorsareidle 0 "when sv_maxidle is not 0, kick idle spectators too" +set sv_maxidle_alsokickspectators 1 "when sv_maxidle is > 0, kick idle spectators as well as players" set sv_maxidle_slots 0 "when not 0, only kick idlers when this many or less player slots are available" set sv_maxidle_slots_countbots 1 "count bots as player slots"