Browse Source

Fixed crossbow fire on empty sequence not playing. (#207)

hl_urbicide
Marc-Antoine Lortie 3 years ago committed by GitHub
parent
commit
ec2826a96a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      cl_dll/ev_hldm.cpp
  2. 4
      dlls/crossbow.cpp

4
cl_dll/ev_hldm.cpp

@ -1246,7 +1246,7 @@ void EV_FireCrossbow2( event_args_t *args )
{ {
if( args->iparam1 ) if( args->iparam1 )
gEngfuncs.pEventAPI->EV_WeaponAnimation( CROSSBOW_FIRE1, 1 ); gEngfuncs.pEventAPI->EV_WeaponAnimation( CROSSBOW_FIRE1, 1 );
else if( args->iparam2 ) else
gEngfuncs.pEventAPI->EV_WeaponAnimation( CROSSBOW_FIRE3, 1 ); gEngfuncs.pEventAPI->EV_WeaponAnimation( CROSSBOW_FIRE3, 1 );
} }
@ -1322,7 +1322,7 @@ void EV_FireCrossbow( event_args_t *args )
{ {
if( args->iparam1 ) if( args->iparam1 )
gEngfuncs.pEventAPI->EV_WeaponAnimation( CROSSBOW_FIRE1, 1 ); gEngfuncs.pEventAPI->EV_WeaponAnimation( CROSSBOW_FIRE1, 1 );
else if ( args->iparam2 ) else
gEngfuncs.pEventAPI->EV_WeaponAnimation( CROSSBOW_FIRE3, 1 ); gEngfuncs.pEventAPI->EV_WeaponAnimation( CROSSBOW_FIRE3, 1 );
V_PunchAxis( 0.0f, -2.0f ); V_PunchAxis( 0.0f, -2.0f );

4
dlls/crossbow.cpp

@ -374,7 +374,7 @@ void CCrossbow::FireSniperBolt()
flags = 0; flags = 0;
#endif #endif
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usCrossbow2, 0.0f, g_vecZero, g_vecZero, 0, 0, m_iClip, m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType], 0, 0 ); PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usCrossbow2, 0.0f, g_vecZero, g_vecZero, 0, 0, m_iClip, 0, 0, 0 );
// player "shoot" animation // player "shoot" animation
m_pPlayer->SetAnimation( PLAYER_ATTACK1 ); m_pPlayer->SetAnimation( PLAYER_ATTACK1 );
@ -417,7 +417,7 @@ void CCrossbow::FireBolt()
flags = 0; flags = 0;
#endif #endif
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usCrossbow, 0.0f, g_vecZero, g_vecZero, 0, 0, m_iClip, m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType], 0, 0 ); PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usCrossbow, 0.0f, g_vecZero, g_vecZero, 0, 0, m_iClip, 0, 0, 0 );
// player "shoot" animation // player "shoot" animation
m_pPlayer->SetAnimation( PLAYER_ATTACK1 ); m_pPlayer->SetAnimation( PLAYER_ATTACK1 );

Loading…
Cancel
Save