mirror of
https://github.com/YGGverse/hlsdk-portable.git
synced 2025-01-24 05:34:18 +00:00
Remove useless casts.
This commit is contained in:
parent
b7f7d6632d
commit
3a6b54c8f8
@ -164,7 +164,7 @@ void CPython::SecondaryAttack( void )
|
|||||||
flags = 0;
|
flags = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usFirePython, 0.0, (float *)&g_vecZero, (float *)&g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usFirePython, 0.0, g_vecZero, g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
||||||
|
|
||||||
if( !m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0 )
|
if( !m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0 )
|
||||||
// HEV suit - indicate out of ammo condition
|
// HEV suit - indicate out of ammo condition
|
||||||
|
@ -158,7 +158,7 @@ void Cak47::PrimaryAttack()
|
|||||||
flags = 0;
|
flags = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usak47, 0.0, (float *)&g_vecZero, (float *)&g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usak47, 0.0, g_vecZero, g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
||||||
|
|
||||||
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
||||||
// HEV suit - indicate out of ammo condition
|
// HEV suit - indicate out of ammo condition
|
||||||
@ -228,7 +228,7 @@ void Cak47::SecondaryAttack( void )
|
|||||||
flags = 0;
|
flags = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usak47, 0.0, (float *)&g_vecZero, (float *)&g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usak47, 0.0, g_vecZero, g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
||||||
|
|
||||||
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
||||||
// HEV suit - indicate out of ammo condition
|
// HEV suit - indicate out of ammo condition
|
||||||
|
@ -181,7 +181,7 @@ void CShotgunA::PrimaryAttack()
|
|||||||
vecDir = m_pPlayer->FireBulletsPlayer( 8, vecSrc, vecAiming, VECTOR_CONE_10DEGREES, 2048, BULLET_PLAYER_BUCKSHOT, 0, 0, m_pPlayer->pev, m_pPlayer->random_seed );
|
vecDir = m_pPlayer->FireBulletsPlayer( 8, vecSrc, vecAiming, VECTOR_CONE_10DEGREES, 2048, BULLET_PLAYER_BUCKSHOT, 0, 0, m_pPlayer->pev, m_pPlayer->random_seed );
|
||||||
}
|
}
|
||||||
|
|
||||||
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usSingleFire, 0.0, (float *)&g_vecZero, (float *)&g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usSingleFire, 0.0, g_vecZero, g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
||||||
|
|
||||||
|
|
||||||
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
||||||
@ -324,4 +324,3 @@ void CShotgunA::WeaponIdle( void )
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -209,7 +209,7 @@ void CEagel::EagelFire( float flSpread, float flCycleTime, BOOL fUseAutoAim )
|
|||||||
Vector vecDir;
|
Vector vecDir;
|
||||||
vecDir = m_pPlayer->FireBulletsPlayer( 1, vecSrc, vecAiming, Vector( flSpread, flSpread, flSpread ), 8192, BULLET_PLAYER_9MM, 0, 0, m_pPlayer->pev, m_pPlayer->random_seed );
|
vecDir = m_pPlayer->FireBulletsPlayer( 1, vecSrc, vecAiming, Vector( flSpread, flSpread, flSpread ), 8192, BULLET_PLAYER_9MM, 0, 0, m_pPlayer->pev, m_pPlayer->random_seed );
|
||||||
|
|
||||||
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), fUseAutoAim ? m_usFireEagel1 : m_usFireEagel2, 0.0, (float *)&g_vecZero, (float *)&g_vecZero, vecDir.x, vecDir.y, 0, 0, ( m_iClip == 0 ) ? 1 : 0, 0 );
|
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), fUseAutoAim ? m_usFireEagel1 : m_usFireEagel2, 0.0, g_vecZero, g_vecZero, vecDir.x, vecDir.y, 0, 0, ( m_iClip == 0 ) ? 1 : 0, 0 );
|
||||||
|
|
||||||
m_flNextPrimaryAttack = m_flNextSecondaryAttack = GetNextAttackDelay( flCycleTime );
|
m_flNextPrimaryAttack = m_flNextSecondaryAttack = GetNextAttackDelay( flCycleTime );
|
||||||
|
|
||||||
|
@ -196,7 +196,7 @@ int CHands::Swing( int fFirst )
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
PLAYBACK_EVENT_FULL( FEV_NOTHOST, m_pPlayer->edict(), m_usHands,
|
PLAYBACK_EVENT_FULL( FEV_NOTHOST, m_pPlayer->edict(), m_usHands,
|
||||||
0.0, (float *)&g_vecZero, (float *)&g_vecZero, 0, 0, 0,
|
0.0, g_vecZero, g_vecZero, 0, 0, 0,
|
||||||
0.0, 0, 0.0 );
|
0.0, 0, 0.0 );
|
||||||
|
|
||||||
|
|
||||||
|
@ -166,7 +166,7 @@ void CMinigun::PrimaryAttack()
|
|||||||
flags = 0;
|
flags = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usminigun, 0.0, (float *)&g_vecZero, (float *)&g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usminigun, 0.0, g_vecZero, g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
||||||
|
|
||||||
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
||||||
// HEV suit - indicate out of ammo condition
|
// HEV suit - indicate out of ammo condition
|
||||||
@ -240,7 +240,7 @@ void CMinigun::SecondaryAttack( void )
|
|||||||
flags = 0;
|
flags = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usminigun, 0.0, (float *)&g_vecZero, (float *)&g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usminigun, 0.0, g_vecZero, g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
||||||
|
|
||||||
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
||||||
// HEV suit - indicate out of ammo condition
|
// HEV suit - indicate out of ammo condition
|
||||||
@ -320,7 +320,7 @@ class CMinigunAmmoClip : public CBasePlayerAmmo
|
|||||||
return bResult;
|
return bResult;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
LINK_ENTITY_TO_CLASS( ammo_minigun, CMinigunAmmoClip );
|
LINK_ENTITY_TO_CLASS( ammo_minigun, CMinigunAmmoClip )
|
||||||
|
|
||||||
class CMinigunChainammo : public CBasePlayerAmmo
|
class CMinigunChainammo : public CBasePlayerAmmo
|
||||||
{
|
{
|
||||||
@ -345,23 +345,5 @@ class CMinigunChainammo : public CBasePlayerAmmo
|
|||||||
return bResult;
|
return bResult;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
LINK_ENTITY_TO_CLASS( ammo_minigunbox, CMinigunChainammo );
|
LINK_ENTITY_TO_CLASS( ammo_minigunbox, CMinigunChainammo )
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -180,7 +180,7 @@ void CMP41a::PrimaryAttack()
|
|||||||
flags = 0;
|
flags = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usMP41a, 0.0, (float *)&g_vecZero, (float *)&g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usMP41a, 0.0, g_vecZero, g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
||||||
|
|
||||||
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
||||||
// HEV suit - indicate out of ammo condition
|
// HEV suit - indicate out of ammo condition
|
||||||
|
@ -180,7 +180,7 @@ flags = FEV_NOTHOST;
|
|||||||
#else
|
#else
|
||||||
flags = 0;
|
flags = 0;
|
||||||
#endif
|
#endif
|
||||||
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), fUseAutoAim ? m_usFireEagle : m_usFireEagle, 0.0, (float *)&g_vecZero, (float *)&g_vecZero, 0.0, 0.0, 0, 0, ( m_iClip == 0 ) ? 1 : 0, 0 );
|
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), fUseAutoAim ? m_usFireEagle : m_usFireEagle, 0.0, g_vecZero, g_vecZero, 0.0, 0.0, 0, 0, ( m_iClip == 0 ) ? 1 : 0, 0 );
|
||||||
|
|
||||||
// player "shoot" animation
|
// player "shoot" animation
|
||||||
m_pPlayer->SetAnimation( PLAYER_ATTACK1 );
|
m_pPlayer->SetAnimation( PLAYER_ATTACK1 );
|
||||||
@ -392,4 +392,4 @@ void CLaserDot::Revive( void )
|
|||||||
void CLaserDot::Precache( void )
|
void CLaserDot::Precache( void )
|
||||||
{
|
{
|
||||||
PRECACHE_MODEL("sprites/laserdot_e.spr");
|
PRECACHE_MODEL("sprites/laserdot_e.spr");
|
||||||
};
|
};
|
||||||
|
@ -156,7 +156,7 @@ void CShockRifle::PrimaryAttack()
|
|||||||
// SendWeaponAnim( SHOCK_FIRE );
|
// SendWeaponAnim( SHOCK_FIRE );
|
||||||
//shock event
|
//shock event
|
||||||
flags = 0;
|
flags = 0;
|
||||||
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usShockFire, 0.0, (float *)&g_vecZero, (float *)&g_vecZero, 0.0, 0.0, 0, m_iBeam, 0, 0);
|
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usShockFire, 0.0, g_vecZero, g_vecZero, 0.0, 0.0, 0, m_iBeam, 0, 0);
|
||||||
|
|
||||||
EMIT_SOUND_DYN(ENT(m_pPlayer->pev), CHAN_ITEM, "weapons/shock_fire.wav", RANDOM_FLOAT(0.95, 1.0), ATTN_NORM, 0, 93 + RANDOM_LONG(0,0xF));
|
EMIT_SOUND_DYN(ENT(m_pPlayer->pev), CHAN_ITEM, "weapons/shock_fire.wav", RANDOM_FLOAT(0.95, 1.0), ATTN_NORM, 0, 93 + RANDOM_LONG(0,0xF));
|
||||||
|
|
||||||
|
@ -215,7 +215,7 @@ int CSwort::Swing( int fFirst )
|
|||||||
if( fFirst )
|
if( fFirst )
|
||||||
{
|
{
|
||||||
PLAYBACK_EVENT_FULL( FEV_NOTHOST, m_pPlayer->edict(), m_usSwort,
|
PLAYBACK_EVENT_FULL( FEV_NOTHOST, m_pPlayer->edict(), m_usSwort,
|
||||||
0.0, (float *)&g_vecZero, (float *)&g_vecZero, 0, 0, 0,
|
0.0, g_vecZero, g_vecZero, 0, 0, 0,
|
||||||
0.0, 0, 0.0 );
|
0.0, 0, 0.0 );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -168,7 +168,7 @@ void CUZI::PrimaryAttack()
|
|||||||
flags = 0;
|
flags = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usUZI, 0.0, (float *)&g_vecZero, (float *)&g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
PLAYBACK_EVENT_FULL( flags, m_pPlayer->edict(), m_usUZI, 0.0, g_vecZero, g_vecZero, vecDir.x, vecDir.y, 0, 0, 0, 0 );
|
||||||
|
|
||||||
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
if (!m_iClip && m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] <= 0)
|
||||||
// HEV suit - indicate out of ammo condition
|
// HEV suit - indicate out of ammo condition
|
||||||
|
Loading…
x
Reference in New Issue
Block a user