mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-23 17:51:31 +00:00
Update d_clisrv.c
This commit is contained in:
parent
93562b782e
commit
9bbebcbe9e
1 changed files with 10 additions and 6 deletions
|
@ -2815,18 +2815,22 @@ static void Command_Kick(void)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!netgame) // Don't kick Tails in splitscreen!
|
|
||||||
{
|
|
||||||
CONS_Printf(M_GetText("This only works in a netgame.\n"));
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (server || IsPlayerAdmin(consoleplayer))
|
if (server || IsPlayerAdmin(consoleplayer))
|
||||||
{
|
{
|
||||||
UINT8 buf[3 + MAX_REASONLENGTH];
|
UINT8 buf[3 + MAX_REASONLENGTH];
|
||||||
UINT8 *p = buf;
|
UINT8 *p = buf;
|
||||||
const SINT8 pn = nametonum(COM_Argv(1));
|
const SINT8 pn = nametonum(COM_Argv(1));
|
||||||
|
|
||||||
|
// Unlike bans, kicks are used especially to remove bot players, so we'll
|
||||||
|
// need to run a more specific check which allows kicking offline, but
|
||||||
|
// not against splitscreen players.
|
||||||
|
if (splitscreen && (pn == 0 || pn == 1))
|
||||||
|
{
|
||||||
|
CONS_Printf(M_GetText("Splitscreen players cannot be kicked.\n"));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
if (pn == -1 || pn == 0)
|
if (pn == -1 || pn == 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue