mirror of
https://github.com/mapbase-source/source-sdk-2013.git
synced 2025-04-20 16:32:30 +03:00
Lost Soul: Fixed manhack sounds playing on charge and stun
This commit is contained in:
parent
759328b805
commit
f85c30d547
@ -3135,16 +3135,27 @@ void CNPC_Manhack::ShowHostile( bool hostile /*= true*/)
|
||||
//TODO: Open the manhack panels or close them, depending on the state
|
||||
m_bShowingHostile = hostile;
|
||||
|
||||
if ( hostile )
|
||||
PlayAttackSound(hostile);
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose: Play a sound before charging at the player
|
||||
// Input : hostile -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CNPC_Manhack::PlayAttackSound(bool hostile /*= true*/)
|
||||
{
|
||||
if (hostile)
|
||||
{
|
||||
EmitSound( "NPC_Manhack.ChargeAnnounce" );
|
||||
EmitSound("NPC_Manhack.ChargeAnnounce");
|
||||
}
|
||||
else
|
||||
{
|
||||
EmitSound( "NPC_Manhack.ChargeEnd" );
|
||||
EmitSound("NPC_Manhack.ChargeEnd");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
//-----------------------------------------------------------------------------
|
||||
|
@ -102,9 +102,10 @@ public:
|
||||
|
||||
virtual float GetHeadTurnRate( void ) { return 45.0f; } // Degrees per second
|
||||
|
||||
virtual void CheckCollisions(float flInterval);
|
||||
virtual void CheckCollisions(float flInterval);
|
||||
virtual void GatherEnemyConditions( CBaseEntity *pEnemy );
|
||||
virtual void PlayFlySound(void);
|
||||
virtual void PlayFlySound(void);
|
||||
virtual void PlayAttackSound(bool bHostile);
|
||||
virtual void StopLoopingSounds(void);
|
||||
|
||||
void Precache(void);
|
||||
@ -126,7 +127,7 @@ public:
|
||||
|
||||
void SpinBlades(float flInterval);
|
||||
|
||||
virtual void Slice( CBaseEntity *pHitEntity, float flInterval, trace_t &tr );
|
||||
virtual void Slice( CBaseEntity *pHitEntity, float flInterval, trace_t &tr );
|
||||
void Bump( CBaseEntity *pHitEntity, float flInterval, trace_t &tr );
|
||||
void Splash( const Vector &vecSplashPos );
|
||||
|
||||
@ -170,7 +171,7 @@ public:
|
||||
m_iHealth = 0;
|
||||
}
|
||||
|
||||
virtual void ShowHostile(bool hostile = true);
|
||||
virtual void SetEyeState(int state);
|
||||
|
||||
DEFINE_CUSTOM_AI;
|
||||
|
||||
@ -185,7 +186,6 @@ private:
|
||||
void StopBurst( bool bInterruptSchedule = false );
|
||||
|
||||
void UpdatePanels( void );
|
||||
void SetEyeState( int state );
|
||||
|
||||
|
||||
|
||||
@ -206,6 +206,7 @@ private:
|
||||
// Are we being held by the physcannon?
|
||||
bool IsHeldByPhyscannon( );
|
||||
|
||||
void ShowHostile(bool hostile = true);
|
||||
void StartLoitering( const Vector &vecLoiterPosition );
|
||||
void StopLoitering() { m_vecLoiterPosition = vec3_invalid; m_fTimeNextLoiterPulse = gpGlobals->curtime; }
|
||||
bool IsLoitering() { return m_vecLoiterPosition != vec3_invalid; }
|
||||
|
@ -92,7 +92,8 @@ public:
|
||||
|
||||
void MoveToTarget(float flInterval, const Vector &MoveTarget);
|
||||
|
||||
void ShowHostile(bool hostile = true);
|
||||
void PlayAttackSound(bool hostile = true);
|
||||
void SetEyeState(int state);
|
||||
|
||||
DECLARE_DATADESC();
|
||||
|
||||
@ -493,7 +494,7 @@ void CNPC_LostSoul::CheckCollisions(float flInterval)
|
||||
// Purpose:
|
||||
// Input : hostile -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CNPC_LostSoul::ShowHostile(bool hostile /*= true*/)
|
||||
void CNPC_LostSoul::PlayAttackSound(bool hostile /*= true*/)
|
||||
{
|
||||
if (hostile)
|
||||
{
|
||||
@ -505,6 +506,15 @@ void CNPC_LostSoul::ShowHostile(bool hostile /*= true*/)
|
||||
}
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : state -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CNPC_LostSoul::SetEyeState(int state)
|
||||
{
|
||||
// Do nothing for now
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
//
|
||||
|
Loading…
x
Reference in New Issue
Block a user