mirror of
https://github.com/celisej567/source-sdk-2013.git
synced 2026-09-23 20:09:45 +03:00
Integrated Reload_NPC into more animation events and changed weapon_crossbow to be able to use a bodygroup instead of a skin for the empty bolt
This commit is contained in:
@@ -2374,9 +2374,10 @@ bool CBaseCombatWeapon::Reload( void )
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseCombatWeapon::Reload_NPC( void )
|
||||
void CBaseCombatWeapon::Reload_NPC( bool bPlaySound )
|
||||
{
|
||||
WeaponSound( RELOAD_NPC );
|
||||
if (bPlaySound)
|
||||
WeaponSound( RELOAD_NPC );
|
||||
|
||||
if (UsesClipsForAmmo1())
|
||||
{
|
||||
|
||||
@@ -321,7 +321,7 @@ public:
|
||||
bool ReloadsSingly( void ) const;
|
||||
#ifdef MAPBASE
|
||||
// Originally created for the crossbow, can be used to add special NPC reloading behavior
|
||||
virtual void Reload_NPC( void );
|
||||
virtual void Reload_NPC( bool bPlaySound = true );
|
||||
#endif
|
||||
|
||||
virtual bool AutoFiresFullClip( void ) { return false; }
|
||||
|
||||
@@ -398,9 +398,10 @@ bool CWeaponCustomScripted::Reload( void )
|
||||
return BaseClass::Reload();
|
||||
}
|
||||
|
||||
void CWeaponCustomScripted::Reload_NPC( void )
|
||||
void CWeaponCustomScripted::Reload_NPC( bool bPlaySound )
|
||||
{
|
||||
SIMPLE_VOID_OVERRIDE( Reload_NPC, NULL );
|
||||
ScriptVariant_t pArgs[] = { bPlaySound };
|
||||
SIMPLE_VOID_OVERRIDE( Reload_NPC, pArgs );
|
||||
|
||||
BaseClass::Reload_NPC();
|
||||
}
|
||||
|
||||
@@ -77,7 +77,7 @@ public:
|
||||
void FinishReload( void );
|
||||
void AbortReload( void );
|
||||
bool Reload( void );
|
||||
void Reload_NPC( void );
|
||||
void Reload_NPC( bool bPlaySound = true );
|
||||
|
||||
// Weapon firing
|
||||
void PrimaryAttack( void ); // do "+ATTACK"
|
||||
|
||||
Reference in New Issue
Block a user