Skip to content

Commit

Permalink
Merge pull request #105 from malortie/ev_hldm-unused-variables
Browse files Browse the repository at this point in the history
Removed unused variables.
  • Loading branch information
SamVanheer authored Dec 4, 2021
2 parents 667f052 + ebed71e commit 8625b9f
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 23 deletions.
24 changes: 5 additions & 19 deletions cl_dll/ev_hldm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -493,7 +493,6 @@ void EV_FireGlock2(event_args_t* args)
Vector ShellOrigin;
int shell;
Vector vecSrc, vecAiming;
Vector vecSpread;
Vector up, right, forward;

idx = args->entindex;
Expand Down Expand Up @@ -546,9 +545,7 @@ void EV_FireShotGunDouble(event_args_t* args)
Vector ShellOrigin;
int shell;
Vector vecSrc, vecAiming;
Vector vecSpread;
Vector up, right, forward;
float flSpread = 0.01;

idx = args->entindex;
VectorCopy(args->origin, origin);
Expand Down Expand Up @@ -600,9 +597,7 @@ void EV_FireShotGunSingle(event_args_t* args)
Vector ShellOrigin;
int shell;
Vector vecSrc, vecAiming;
Vector vecSpread;
Vector up, right, forward;
float flSpread = 0.01;

idx = args->entindex;
VectorCopy(args->origin, origin);
Expand Down Expand Up @@ -659,7 +654,6 @@ void EV_FireMP5(event_args_t* args)
int shell;
Vector vecSrc, vecAiming;
Vector up, right, forward;
float flSpread = 0.01;

idx = args->entindex;
VectorCopy(args->origin, origin);
Expand Down Expand Up @@ -742,7 +736,6 @@ void EV_FirePython(event_args_t* args)

Vector vecSrc, vecAiming;
Vector up, right, forward;
float flSpread = 0.01;

idx = args->entindex;
VectorCopy(args->origin, origin);
Expand Down Expand Up @@ -831,16 +824,13 @@ void EV_FireGauss(event_args_t* args)
Vector angles;
Vector velocity;
float flDamage = args->fparam1;
int primaryfire = args->bparam1;

bool m_fPrimaryFire = 0 != args->bparam1;
int m_iWeaponVolume = GAUSS_PRIMARY_FIRE_VOLUME;
Vector vecSrc;
Vector vecDest;
edict_t* pentIgnore;
pmtrace_t tr, beam_tr;
float flMaxFrac = 1.0;
int nTotal = 0;
bool fHasPunched = false;
bool fFirstBeam = true;
int nMaxHits = 10;
Expand Down Expand Up @@ -1107,8 +1097,6 @@ void EV_Crowbar(event_args_t* args)
{
int idx;
Vector origin;
Vector angles;
Vector velocity;

idx = args->entindex;
VectorCopy(args->origin, origin);
Expand Down Expand Up @@ -1314,12 +1302,11 @@ void EV_EgonFlareCallback(struct tempent_s* ent, float frametime, float currentt

void EV_EgonFire(event_args_t* args)
{
int idx, iFireState, iFireMode;
int idx, iFireMode;
Vector origin;

idx = args->entindex;
VectorCopy(args->origin, origin);
iFireState = args->iparam1;
iFireMode = args->iparam2;
bool iStartup = 0 != args->bparam1;

Expand Down Expand Up @@ -1351,7 +1338,7 @@ void EV_EgonFire(event_args_t* args)

if (iStartup && EV_IsLocal(idx) && !pBeam && !pBeam2 && !pFlare && 0 != cl_lw->value) //Adrian: Added the cl_lw check for those lital people that hate weapon prediction.
{
Vector vecSrc, vecEnd, origin, angles, forward, right, up;
Vector vecSrc, vecEnd, angles, forward, right, up;
pmtrace_t tr;

cl_entity_t* pl = gEngfuncs.GetEntityByIndex(idx);
Expand Down Expand Up @@ -1471,13 +1458,12 @@ void EV_EgonStop(event_args_t* args)
//======================
void EV_HornetGunFire(event_args_t* args)
{
int idx, iFireMode;
Vector origin, angles, vecSrc, forward, right, up;
int idx;
Vector origin, angles;

idx = args->entindex;
VectorCopy(args->origin, origin);
VectorCopy(args->angles, angles);
iFireMode = args->iparam1;

//Only play the weapon anims if I shot it.
if (EV_IsLocal(idx))
Expand Down Expand Up @@ -1552,7 +1538,7 @@ void EV_TripmineFire(event_args_t* args)
void EV_SnarkFire(event_args_t* args)
{
int idx;
Vector vecSrc, angles, view_ofs, forward;
Vector vecSrc, angles, forward;
pmtrace_t tr;

idx = args->entindex;
Expand Down
4 changes: 2 additions & 2 deletions dlls/egon.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ void CEgon::Attack()

m_flAmmoUseTime = gpGlobals->time; // start using ammo ASAP.

PLAYBACK_EVENT_FULL(flags, m_pPlayer->edict(), m_usEgonFire, 0.0, g_vecZero, g_vecZero, 0.0, 0.0, m_fireState, m_fireMode, 1, 0);
PLAYBACK_EVENT_FULL(flags, m_pPlayer->edict(), m_usEgonFire, 0.0, g_vecZero, g_vecZero, 0.0, 0.0, 0, m_fireMode, 1, 0);

m_shakeTime = 0;

Expand All @@ -200,7 +200,7 @@ void CEgon::Attack()

if (pev->fuser1 <= UTIL_WeaponTimeBase())
{
PLAYBACK_EVENT_FULL(flags, m_pPlayer->edict(), m_usEgonFire, 0, g_vecZero, g_vecZero, 0.0, 0.0, m_fireState, m_fireMode, 0, 0);
PLAYBACK_EVENT_FULL(flags, m_pPlayer->edict(), m_usEgonFire, 0, g_vecZero, g_vecZero, 0.0, 0.0, 0, m_fireMode, 0, 0);
pev->fuser1 = 1000;
}

Expand Down
4 changes: 2 additions & 2 deletions dlls/hornetgun.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ void CHgun::PrimaryAttack()
flags = 0;
#endif

PLAYBACK_EVENT_FULL(flags, m_pPlayer->edict(), m_usHornetFire, 0.0, g_vecZero, g_vecZero, 0.0, 0.0, FIREMODE_TRACK, 0, 0, 0);
PLAYBACK_EVENT_FULL(flags, m_pPlayer->edict(), m_usHornetFire, 0.0, g_vecZero, g_vecZero, 0.0, 0.0, 0, 0, 0, 0);



Expand Down Expand Up @@ -236,7 +236,7 @@ void CHgun::SecondaryAttack()
flags = 0;
#endif

PLAYBACK_EVENT_FULL(flags, m_pPlayer->edict(), m_usHornetFire, 0.0, g_vecZero, g_vecZero, 0.0, 0.0, FIREMODE_FAST, 0, 0, 0);
PLAYBACK_EVENT_FULL(flags, m_pPlayer->edict(), m_usHornetFire, 0.0, g_vecZero, g_vecZero, 0.0, 0.0, 0, 0, 0, 0);


m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType]--;
Expand Down

0 comments on commit 8625b9f

Please sign in to comment.