mirror of
https://github.com/s1lentq/ReGameDLL_CS.git
synced 2024-12-27 07:05:38 +03:00
Do not reduce points for bot suicide due bot_kill command
This commit is contained in:
parent
0bbc4bd55d
commit
5287f2a415
@ -429,6 +429,20 @@ bool CCSBot::StayOnNavMesh()
|
||||
return false;
|
||||
}
|
||||
|
||||
#ifdef REGAMEDLL_FIXES
|
||||
void CCSBot::Kill()
|
||||
{
|
||||
m_LastHitGroup = HITGROUP_GENERIC;
|
||||
|
||||
// have the player kill himself
|
||||
pev->health = 0.0f;
|
||||
Killed(VARS(eoNullEntity), GIB_NEVER);
|
||||
|
||||
if (CSGameRules()->m_pVIP == this)
|
||||
CSGameRules()->m_iConsecutiveVIP = 10;
|
||||
}
|
||||
#endif
|
||||
|
||||
void CCSBot::Panic(CBasePlayer *pEnemy)
|
||||
{
|
||||
if (IsSurprised())
|
||||
|
@ -375,6 +375,10 @@ public:
|
||||
|
||||
bool IsBuying() const;
|
||||
|
||||
#ifdef REGAMEDLL_FIXES
|
||||
void Kill();
|
||||
#endif
|
||||
|
||||
void Panic(CBasePlayer *pEnemy); // look around in panic
|
||||
void Follow(CBasePlayer *pPlayer); // begin following given Player
|
||||
void ContinueFollowing(); // continue following our leader after finishing what we were doing
|
||||
|
@ -408,10 +408,9 @@ void CCSBotManager::ServerCommand(const char *pcmd)
|
||||
|
||||
if (pPlayer->IsBot())
|
||||
{
|
||||
CCSBot *pBot = static_cast<CCSBot *>(pPlayer);
|
||||
if (killThemAll || FStrEq(name, msg))
|
||||
{
|
||||
pPlayer->Kill();
|
||||
}
|
||||
pBot->Kill();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user