Prevent possible crash.

This commit is contained in:
Andrey Akhmichin 2022-11-04 02:11:20 +05:00
parent 5bb0f8ead5
commit 0e6b06df5a
No known key found for this signature in database
GPG Key ID: 1F180D249B0643C0

View File

@ -418,7 +418,7 @@ void CGonome::HandleAnimEvent(MonsterEvent_t *pEvent)
vecSpitOffset = vecArmPos;
UTIL_BloodDrips( vecSpitOffset, UTIL_RandomBloodVector(), BLOOD_COLOR_RED, 35 );
if( pEvent->event == GONOME_AE_THROW )
if( pEvent->event == GONOME_AE_THROW && m_hEnemy != 0 )
{
vecSpitDir = ((m_hEnemy->pev->origin + m_hEnemy->pev->view_ofs) - vecSpitOffset).Normalize();