ivailosp
Great plugin - I'm a big fan.
back on page one someone asked:
Quote:
Originally Posted by lovemf
and can do this?
sv_maxplayers max human players that can join your server
sv_maxslots max max srcds.exe slots
|
and you responded:
Quote:
Originally Posted by ivailosp
...
sv_maxslots? max slots is set to 32 in my plugin - you need more?
|
I think he was requesting if you could ADD that functionality to your plugin.
Could you add the cvar to limit slots AND a separate one to limit human players?
I wanted to set up a reserved slot to kick high ping player when admin connects to my server [running l4dtoolz with bebop for 8 player coop]
cvars in server.cfg:
sm_cvar sv_maxplayers 9 //8 man coop
sm_cvar sv_visiblemaxplayers 8 //-1 default
sm_cvar sv_removehumanlimit 1
sm_cvar sv_unlock_sb_add 1
sm_cvar sv_force_unreserved 1
//sm_cvar z_max_player_zombies 4
sm_cvar survivor_limit 8 //default 4
from sourcemod.cfg:
Quote:
// Specifies how the reserved slots plugin operates. Valid values are:
// 0 : Public slots are used in preference to reserved slots. Reserved slots are freed before public slots.
// 1 : If someone with reserve access joins into a reserved slot, the player with the highest latency and
// no reserved slot access (spectator players are selected first) is kicked to make room. Thus, the reserved
// slots always remains free. The only situation where the reserved slot(s) can become properly occupied is
// if the server is full with reserve slot access clients.
// --
// Requires: reservedslots.smx
// Default: 0
sm_reserve_type 1
// Specifies the number of reserved player slots. Users with the reservation
// admin flag set will be able to join the server when there are no public slots
// remaining. If someone does not have this flag, they will be kicked.
// (Public slots are defined as: maxplayers - number of reserved slots)
// --
// Requires: reservedslots.smx
// Default: 0
sm_reserved_slots 1
// Specifies whether or not reserved slots will be hidden (subtracted from max
// slot count). Valid values are 0 (visible) or 1 (hidden).
// --
// Requires: reservedslots.smx
// Default: 0
sm_hide_slots 1
|
I don't understand too much script, but when reserved slots hides a slot, it changes sv_visiblemaxplayers according to the max slots.
From reservedslots.sp:
Code:
SetConVarInt(sv_visiblemaxplayers, g_MaxClients);
}
public OnMapStart()
{
g_MaxClients = GetMaxClients();
if (GetConVarBool(sm_hide_slots))
{
SetVisibleMaxSlots(GetClientCount(false), g_MaxClients - GetConVarInt(sm_reserved_slots));
}
}
public OnConfigsExecuted()
{
if (GetConVarBool(sm_hide_slots))
{
SetVisibleMaxSlots(GetClientCount(false), g_MaxClients - GetConVarInt(sm_reserved_slots));
}
}
I have sv_visiblemaxplayers set to 8, but the reservedslots plugin changes it to 31 when sm_hide_slots set to 1.
Would you be able to fix this by adding a new cvar?
or is this problem beyond the scope of your plugin?