This commit is contained in:
Night Owl 2017-07-11 01:40:26 +05:00
parent 77d077c83d
commit 2df762e705
1 changed files with 13 additions and 6 deletions

View File

@ -375,6 +375,13 @@ void CPlatTrigger::Touch( CBaseEntity *pOther )
CFuncPlat *pPlatform = (CFuncPlat*)(CBaseEntity*)m_hPlatform;
if( FNullEnt( pPlatform ) )
{
// The target platform has been removed, remove myself as well. - Solokiller
UTIL_Remove( this );
return;
}
// Ignore touches by corpses
if( !pOther->IsAlive() )
return;
@ -857,8 +864,8 @@ void CFuncTrain::Precache( void )
case 1:
PRECACHE_SOUND( "plats/train2.wav" );
PRECACHE_SOUND( "plats/train1.wav" );
pev->noise = MAKE_STRING("plats/train2.wav" );
pev->noise1 = MAKE_STRING("plats/train1.wav" );
pev->noise = MAKE_STRING( "plats/train2.wav" );
pev->noise1 = MAKE_STRING( "plats/train1.wav" );
break;
case 2:
PRECACHE_SOUND( "plats/platmove1.wav" );