diff --git a/src/game/server/neo/bot/behavior/neo_bot_grenade_throw.cpp b/src/game/server/neo/bot/behavior/neo_bot_grenade_throw.cpp index ce1f60ef0..5a3a80074 100644 --- a/src/game/server/neo/bot/behavior/neo_bot_grenade_throw.cpp +++ b/src/game/server/neo/bot/behavior/neo_bot_grenade_throw.cpp @@ -343,6 +343,11 @@ ActionResult< CNEOBot > CNEOBotGrenadeThrow::Update( CNEOBot *me, float interval //--------------------------------------------------------------------------------------------- void CNEOBotGrenadeThrow::OnEnd( CNEOBot *me, Action< CNEOBot > *nextAction ) { + if (!NEORules()) // This can get called on de-init + { + return; + } + // Restore looking and weapon handling behaviors me->PopRequiredWeapon(); me->StartLookingAroundForEnemies(); diff --git a/src/game/server/neo/bot/neo_bot_vision.cpp b/src/game/server/neo/bot/neo_bot_vision.cpp index 75d240feb..61b2f7b8d 100644 --- a/src/game/server/neo/bot/neo_bot_vision.cpp +++ b/src/game/server/neo/bot/neo_bot_vision.cpp @@ -90,6 +90,11 @@ void CNEOBotVision::UpdatePotentiallyVisibleNPCVector( void ) */ bool CNEOBotVision::IsIgnored( CBaseEntity* subject ) const { + if (!NEORules()) // This can get called on de-init + { + return true; + } + CNEOBot* me = ( CNEOBot* )GetBot()->GetEntity(); if ( me->IsAttentionFocused() )