some changes in bot's code

This commit is contained in:
Lukasz Wlasinksi
2004-08-12 13:22:34 +00:00
parent 3155a300c6
commit 796a7ad4d7
9 changed files with 11 additions and 10 deletions

View File

@ -90,6 +90,7 @@ void Grenades::clear()
void CPlayer::Disconnect(){
ingame = false;
bot = false;
savedScore = 0;
if ( ignoreBots(pEdict) || !isModuleActive() ) // ignore if he is bot and bots rank is disabled or module is paused
@ -150,6 +151,7 @@ void CPlayer::Init( int pi, edict_t* pe )
current = 0;
clearStats = 0.0f;
ingame = false;
bot = false;
savedScore = 0;
}

View File

@ -195,13 +195,13 @@ void ServerDeactivate() {
BOOL ClientConnect_Post( edict_t *pEntity, const char *pszName, const char *pszAddress, char szRejectReason[ 128 ] ){
GET_PLAYER_POINTER(pEntity)->Connect(pszName,pszAddress);
RETURN_META_VALUE(MRES_IGNORED, TRUE);
}
void ClientDisconnect( edict_t *pEntity ) {
CPlayer *pPlayer = GET_PLAYER_POINTER(pEntity);
if (pPlayer->ingame)
pPlayer->Disconnect();