mirror of
https://github.com/YGGverse/hlsdk-portable.git
synced 2025-02-04 19:14:30 +00:00
Prevent crash on tank and spectator
This commit is contained in:
parent
0e48f74d0b
commit
3e3e35d1de
@ -2481,7 +2481,7 @@ void CBasePlayer::PostThink()
|
||||
}
|
||||
|
||||
// Handle Tank controlling
|
||||
if( m_pTank != NULL )
|
||||
if( m_pTank && m_state == STATE_SPAWNED )
|
||||
{
|
||||
// if they've moved too far from the gun, or selected a weapon, unuse the gun
|
||||
if( m_pTank->OnControls( pev ) && !pev->weaponmodel )
|
||||
|
Loading…
x
Reference in New Issue
Block a user