//----------------------------------------------------------------------------- // Purpose: Draws the model //----------------------------------------------------------------------------- int C_WeaponCombat_ChargeablePlasma::DrawModel( int flags ) { int retval = BaseClass::DrawModel( flags ); if (retval == 0) return 0; if (m_bCharging && IsCarrierAlive()) { // Draw the charging effect float flSize = 20 * m_flPower + 10; DrawChargingEffect( flSize, this ); } return retval; }
//----------------------------------------------------------------------------- // Purpose: //----------------------------------------------------------------------------- void CTFFlameThrower::OnDataChanged(DataUpdateType_t updateType) { BaseClass::OnDataChanged(updateType); if ( IsCarrierAlive() && ( WeaponState() == WEAPON_IS_ACTIVE ) && ( GetPlayerOwner()->GetAmmoCount( m_iPrimaryAmmoType ) > 0 ) ) { if ( m_iWeaponState > FT_STATE_IDLE ) { if ( m_iWeaponState != FT_STATE_AIRBLASTING || !GetPlayerOwner()->IsLocalPlayer() ) { StartFlame(); } } else { StartPilotLight(); } } else { StopFlame(); StopPilotLight(); } }