mirror of
https://github.com/ineedbots/cod2m.git
synced 2025-04-19 16:02:53 +00:00
Drop dead bot slots
This commit is contained in:
parent
bb54910614
commit
a9fe1047bd
@ -16,6 +16,13 @@ namespace Components
|
||||
{
|
||||
int cl_num = cl - Game::svs->clients;
|
||||
|
||||
if (cl->state < Game::CS_ACTIVE)
|
||||
{
|
||||
Game::SV_DropClient(cl, "EXE_DISCONNECTED");
|
||||
cl->state = Game::CS_FREE;
|
||||
return;
|
||||
}
|
||||
|
||||
Game::usercmd_t cmd = {};
|
||||
cmd.serverTime = Game::svs->time;
|
||||
|
||||
|
@ -68,5 +68,18 @@ namespace Game
|
||||
call func_loc;
|
||||
}
|
||||
}
|
||||
|
||||
void SV_DropClient(Game::client_t* client, const char* reason)
|
||||
{
|
||||
int func_loc = 0x454750;
|
||||
|
||||
__asm
|
||||
{
|
||||
push reason;
|
||||
mov eax, client;
|
||||
call func_loc;
|
||||
add esp, 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -35,4 +35,5 @@ namespace Game
|
||||
|
||||
|
||||
void SV_ClientThink(Game::usercmd_s*, Game::client_t*);
|
||||
void SV_DropClient(Game::client_t*, const char*);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user