- Added team-killer punishment
- Added the really convoluted round loss bonus logic, thanks cstrike wiki - Tweaked some existing money bonuses to reflect the real-world values of CS 1.5 - Implemented some Fire-In-The-Hole radio notices when throwing nades - Added workaround for the shotgun reload glitch that comes from autoreloading. Proper fix soon
This commit is contained in:
parent
9ce909e291
commit
d1f4e6b690
23 changed files with 218 additions and 86 deletions
|
@ -154,10 +154,10 @@ void Game_PutClientInServer(void)
|
|||
Spawn_MakeSpectator();
|
||||
Spawn_ObserverCam();
|
||||
self.SendEntity = Player_SendEntity;
|
||||
|
||||
|
||||
// Because we don't want to reset these when we die
|
||||
Money_AddMoney(self, autocvar_mp_startmoney);
|
||||
|
||||
|
||||
if (cvar("mp_timelimit") > 0) {
|
||||
if (autocvar_fcs_voxannounce == TRUE) {
|
||||
float fTimeLeft = cvar("mp_timelimit") - (time / 60);
|
||||
|
|
|
@ -73,11 +73,11 @@ int Damage_ShouldDamage(float fTargetTeam, float fAttackerTeam)
|
|||
} else if (fAttackerTeam == TEAM_VIP) {
|
||||
fAttackerTeam = TEAM_CT;
|
||||
}
|
||||
|
||||
|
||||
if (fTargetTeam == fAttackerTeam) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
|
||||
return TRUE;
|
||||
#endif
|
||||
}
|
||||
|
@ -91,9 +91,9 @@ Generic function that applies damage, pain and suffering
|
|||
*/
|
||||
void Damage_Apply(entity eTarget, entity eAttacker, float iDamage, vector vHitPos, int iSkipArmor)
|
||||
{
|
||||
#ifdef CSTRIKE
|
||||
// Modify the damage based on the location
|
||||
if (trace_surface_id == BODY_HEAD) {
|
||||
/* Modify the damage based on the location */
|
||||
switch (trace_surface_id) {
|
||||
case BODY_HEAD:
|
||||
if (eTarget.iEquipment & EQUIPMENT_HELMET) {
|
||||
sound(self, CHAN_ITEM, "weapons/ric_metal-2.wav", 1, ATTN_IDLE);
|
||||
iDamage = 0;
|
||||
|
@ -101,13 +101,16 @@ void Damage_Apply(entity eTarget, entity eAttacker, float iDamage, vector vHitPo
|
|||
} else {
|
||||
iDamage *= 4;
|
||||
}
|
||||
} else if (trace_surface_id == BODY_STOMACH) {
|
||||
break;
|
||||
case BODY_STOMACH:
|
||||
iDamage *= 0.9;
|
||||
} else if (trace_surface_id == BODY_LEGLEFT) {
|
||||
iDamage *= 0.4;
|
||||
} else if (trace_surface_id == BODY_LEGRIGHT) {
|
||||
break;
|
||||
case BODY_LEGLEFT:
|
||||
case BODY_LEGRIGHT:
|
||||
iDamage *= 0.4;
|
||||
break;
|
||||
}
|
||||
|
||||
dprint(sprintf("[DEBUG] Hit Bodypart: %s\n", Damage_GetHitLocation(trace_surface_id)));
|
||||
|
||||
if (eTarget != eAttacker) {
|
||||
|
@ -120,15 +123,15 @@ void Damage_Apply(entity eTarget, entity eAttacker, float iDamage, vector vHitPo
|
|||
|
||||
eTarget.velocity = [0,0,0];
|
||||
|
||||
// Apply the damage finally
|
||||
/* Apply the damage finally */
|
||||
if (eTarget.armor) {
|
||||
float fRatio = 0.5;
|
||||
|
||||
if (eAttacker.weapon) {
|
||||
fRatio *= wptTable[eAttacker.weapon].fWeaponArmorRatio;
|
||||
}
|
||||
|
||||
// Simple implementation of how kevlar damage is calculated
|
||||
|
||||
/* Simple implementation of how kevlar damage is calculated */
|
||||
float fNewDmg = iDamage * fRatio;
|
||||
float fNewArmor = (iDamage - fNewDmg) / 2;
|
||||
|
||||
|
@ -158,8 +161,8 @@ void Damage_Apply(entity eTarget, entity eAttacker, float iDamage, vector vHitPo
|
|||
eTarget.dmg_take = (float)iDamage;
|
||||
}
|
||||
eTarget.dmg_inflictor = eAttacker;
|
||||
|
||||
// Special monetary punishment for hostage murderers
|
||||
|
||||
/* Special monetary punishment for hostage murderers */
|
||||
if (eTarget.classname == "hostage_entity") {
|
||||
if (eTarget.health > 0) {
|
||||
Money_AddMoney(eAttacker, autocvar_fcs_penalty_pain); // Pain
|
||||
|
@ -168,26 +171,29 @@ void Damage_Apply(entity eTarget, entity eAttacker, float iDamage, vector vHitPo
|
|||
}
|
||||
}
|
||||
|
||||
// Target is dead and a client....
|
||||
/* Target is dead and a client.... */
|
||||
if (eTarget.health <= 0) {
|
||||
if (eTarget.flags & FL_CLIENT) {
|
||||
eTarget.fDeaths++;
|
||||
forceinfokey(eTarget, "*deaths", ftos(eTarget.fDeaths));
|
||||
}
|
||||
|
||||
|
||||
if ((eTarget.flags & FL_CLIENT) && (eAttacker.flags & FL_CLIENT)) {
|
||||
// Don't encourage them to kill their own team members for $$$
|
||||
/* Don't encourage them to kill their own team members for $$$ */
|
||||
if (Damage_ShouldDamage(eTarget.team, eAttacker.team) == TRUE) {
|
||||
eAttacker.frags++;
|
||||
Money_AddMoney(eAttacker, autocvar_fcs_reward_kill);
|
||||
} else {
|
||||
eAttacker.frags--;
|
||||
/* Team killer */
|
||||
if (eTarget != eAttacker) {
|
||||
Money_AddMoney(eAttacker, -3300);
|
||||
}
|
||||
}
|
||||
|
||||
Damage_CastOrbituary(eAttacker, eTarget, eAttacker.weapon, trace_surface_id == BODY_HEAD ? TRUE:FALSE);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
entity eOld = self;
|
||||
self = eTarget;
|
||||
|
||||
|
@ -199,7 +205,6 @@ void Damage_Apply(entity eTarget, entity eAttacker, float iDamage, vector vHitPo
|
|||
}
|
||||
|
||||
self = eOld;
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -212,16 +217,8 @@ from a plain geographical standpoint
|
|||
*/
|
||||
float Damage_CheckAttack(entity eTarget, vector vAttackPos)
|
||||
{
|
||||
if (eTarget.movetype == MOVETYPE_PUSH) {
|
||||
traceline(vAttackPos, 0.5 * (eTarget.absmin + eTarget.absmax), TRUE, self);
|
||||
|
||||
if (trace_fraction == 1) {
|
||||
return TRUE;
|
||||
}
|
||||
if (trace_ent == eTarget) {
|
||||
return TRUE;
|
||||
}
|
||||
return FALSE;
|
||||
if (eTarget.solid == SOLID_BSP) {
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
traceline(vAttackPos, eTarget.origin, TRUE, self);
|
||||
|
@ -255,34 +252,28 @@ Damage_Radius
|
|||
Even more pain and suffering, mostly used for explosives
|
||||
=================
|
||||
*/
|
||||
void Damage_Radius(vector vOrigin, entity eAttacker, float fDamage, float fRadius, int iCheckClip)
|
||||
void Damage_Radius(vector org, entity eAttacker, float fDamage, float fRadius, int iCheckClip)
|
||||
{
|
||||
for (entity eDChain = world; (eDChain = findfloat(eDChain, takedamage, DAMAGE_YES));) {
|
||||
for (entity c = world; (c = findfloat(c, takedamage, DAMAGE_YES));) {
|
||||
vector vecRealPos;
|
||||
vecRealPos[0] = eDChain.absmin[0] + (0.5 * (eDChain.absmax[0] - eDChain.absmin[0]));
|
||||
vecRealPos[1] = eDChain.absmin[1] + (0.5 * (eDChain.absmax[1] - eDChain.absmin[1]));
|
||||
vecRealPos[2] = eDChain.absmin[2] + (0.5 * (eDChain.absmax[2] - eDChain.absmin[2]));
|
||||
vecRealPos[0] = c.absmin[0] + (0.5 * (c.absmax[0] - c.absmin[0]));
|
||||
vecRealPos[1] = c.absmin[1] + (0.5 * (c.absmax[1] - c.absmin[1]));
|
||||
vecRealPos[2] = c.absmin[2] + (0.5 * (c.absmax[2] - c.absmin[2]));
|
||||
|
||||
float fDist = vlen(vOrigin - vecRealPos);
|
||||
//vector vPush;
|
||||
float fDist = vlen(org - vecRealPos);
|
||||
|
||||
if (fDist > fRadius) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (Damage_CheckAttack(eDChain, vOrigin) || iCheckClip == FALSE) {
|
||||
float fDiff = vlen(vOrigin - vecRealPos);
|
||||
if (Damage_CheckAttack(c, org) || iCheckClip == FALSE) {
|
||||
float fDiff = vlen(org - vecRealPos);
|
||||
|
||||
fDiff = (fRadius - fDiff) / fRadius;
|
||||
fDamage = rint(fDamage * fDiff);
|
||||
|
||||
if (fDiff > 0) {
|
||||
Damage_Apply(eDChain, eAttacker, fDamage, eDChain.origin, TRUE);
|
||||
/*if (eDChain.movetype != MOVETYPE_NONE) {
|
||||
vPush = vectoangles(vecRealPos - vOrigin);
|
||||
makevectors(vPush);
|
||||
eDChain.velocity += (v_forward * fDamage * 5) + (v_up * fDamage * 2.5);
|
||||
}*/
|
||||
Damage_Apply(c, eAttacker, fDamage, vecRealPos, 0);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -29,6 +29,9 @@ void func_vip_safetyzone::touch(void)
|
|||
{
|
||||
if (other.classname == "player") {
|
||||
if (other.team == TEAM_VIP) {
|
||||
/* In Assassination, all Counter-Terrorists receive a $2500
|
||||
* reward if they won by successfully guaranteeing
|
||||
* the escape of the VIP. */
|
||||
Rules_RoundOver(TEAM_CT, 2500, FALSE);
|
||||
VIP_Rescue(other);
|
||||
}
|
||||
|
|
|
@ -74,3 +74,102 @@ void Money_ResetTeamReward(void)
|
|||
iMoneyReward_T = 0;
|
||||
iMoneyReward_CT = 0;
|
||||
}
|
||||
|
||||
int iLosses_CT;
|
||||
int iLosses_T;
|
||||
int iWinstreak_CT;
|
||||
int iWinstreak_T;
|
||||
int iBonus_CT;
|
||||
int iBonus_T;
|
||||
|
||||
int Money_GetLosses(int team)
|
||||
{
|
||||
if (team == TEAM_T) {
|
||||
return iLosses_T;
|
||||
} else {
|
||||
return iLosses_CT;
|
||||
}
|
||||
}
|
||||
int Money_HasBonus(int team)
|
||||
{
|
||||
if (team == TEAM_T) {
|
||||
return iBonus_T;
|
||||
} else {
|
||||
return iBonus_CT;
|
||||
}
|
||||
}
|
||||
|
||||
void Money_HandleRoundReward(int winner)
|
||||
{
|
||||
int loser;
|
||||
|
||||
if (winner == TEAM_CT) {
|
||||
iWinstreak_CT++;
|
||||
iWinstreak_T = 0;
|
||||
iLosses_T++;
|
||||
iLosses_CT = 0;
|
||||
loser = TEAM_T;
|
||||
|
||||
if (iWinstreak_CT >= 2) {
|
||||
iBonus_CT = TRUE;
|
||||
}
|
||||
} else if (winner == TEAM_T) {
|
||||
iWinstreak_T++;
|
||||
iWinstreak_CT = 0;
|
||||
iLosses_CT++;
|
||||
iLosses_T = 0;
|
||||
loser = TEAM_CT;
|
||||
|
||||
if (iWinstreak_T >= 2) {
|
||||
iBonus_T = TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
/* After the condition of a team winning two consecutive rounds is
|
||||
* satisfied then the loss bonus money changes to above where their
|
||||
* first loss means they receive $1500 and not $1400. */
|
||||
if (Money_HasBonus(loser)) {
|
||||
switch (Money_GetLosses(loser)) {
|
||||
case 1:
|
||||
Money_QueTeamReward(loser, 1500);
|
||||
break;
|
||||
case 2:
|
||||
Money_QueTeamReward(loser, 2000);
|
||||
break;
|
||||
case 3:
|
||||
Money_QueTeamReward(loser, 2500);
|
||||
break;
|
||||
default:
|
||||
Money_QueTeamReward(loser, 3000);
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
switch (Money_GetLosses(loser)) {
|
||||
case 1:
|
||||
Money_QueTeamReward(loser, 1400);
|
||||
break;
|
||||
case 2:
|
||||
Money_QueTeamReward(loser, 1900);
|
||||
break;
|
||||
case 3:
|
||||
Money_QueTeamReward(loser, 2400);
|
||||
break;
|
||||
case 4:
|
||||
Money_QueTeamReward(loser, 2900);
|
||||
break;
|
||||
default:
|
||||
Money_QueTeamReward(loser, 3400);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void Money_ResetRoundReward(void)
|
||||
{
|
||||
iLosses_CT =
|
||||
iLosses_T =
|
||||
iWinstreak_CT =
|
||||
iWinstreak_T =
|
||||
iBonus_CT =
|
||||
iBonus_T = 0;
|
||||
}
|
||||
|
|
|
@ -133,6 +133,8 @@ void Player_Death(int iHitBody)
|
|||
|
||||
Rules_CountPlayers();
|
||||
|
||||
/* In Assassination, all Terrorists receive a $2500
|
||||
* reward if they won by killing the VIP. */
|
||||
if (self.team == TEAM_VIP) {
|
||||
Rules_RoundOver(TEAM_T, 2500, FALSE);
|
||||
return;
|
||||
|
|
|
@ -209,16 +209,15 @@ void Rules_RoundOver( int iTeamWon, int iMoneyReward, float fSilent ) {
|
|||
Radio_BroadcastMessage( RADIO_TERWIN );
|
||||
}
|
||||
iWon_T++;
|
||||
|
||||
// FIXME: Calculate the proper loss values
|
||||
Money_QueTeamReward( TEAM_CT, 1400 );
|
||||
|
||||
Money_HandleRoundReward(TEAM_T);
|
||||
} else if ( iTeamWon == TEAM_CT ) {
|
||||
if ( fSilent == FALSE ) {
|
||||
Radio_BroadcastMessage( RADIO_CTWIN );
|
||||
}
|
||||
iWon_CT++;
|
||||
// FIXME: Calculate the proper loss values
|
||||
Money_QueTeamReward( TEAM_T, 1400 );
|
||||
|
||||
Money_HandleRoundReward(TEAM_CT);
|
||||
} else {
|
||||
if ( fSilent == FALSE ) {
|
||||
Radio_BroadcastMessage( RADIO_ROUNDDRAW );
|
||||
|
@ -243,6 +242,8 @@ void Rules_TimeOver( void ) {
|
|||
if ( iVIPZones > 0 ) {
|
||||
Rules_RoundOver( TEAM_T, 3250, FALSE );
|
||||
} else if ( iBombZones > 0 ) {
|
||||
/* In Bomb Defusal, all Counter-Terrorists receive $3250
|
||||
* if they won running down the time. */
|
||||
Rules_RoundOver( TEAM_CT, 3250, FALSE );
|
||||
} else if ( iHostagesMax > 0 ) {
|
||||
// TODO: Broadcast_Print: Hostages have not been rescued!
|
||||
|
@ -313,12 +314,23 @@ void Rules_DeathCheck(void)
|
|||
Rules_RoundOver( FALSE, 0, FALSE );
|
||||
}
|
||||
} else {
|
||||
int winner;
|
||||
if ( ( self.team == TEAM_T ) && ( iAlivePlayers_T == 0 ) ) {
|
||||
if ( iBombPlanted == FALSE ) {
|
||||
Rules_RoundOver( TEAM_CT, 3600, FALSE );
|
||||
}
|
||||
winner = TEAM_CT;
|
||||
} else if ( ( self.team == TEAM_CT ) && ( iAlivePlayers_CT == 0 ) ) {
|
||||
Rules_RoundOver( TEAM_T, 3600, FALSE );
|
||||
winner = TEAM_T;
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
|
||||
if (iBombZones > 0) {
|
||||
/* In Bomb Defusal, the winning team receives $3250
|
||||
* if they won by eliminating the enemy team. */
|
||||
Rules_RoundOver(winner, 3250, FALSE);
|
||||
} else {
|
||||
/* In Hostage Rescue, the winning team receives $3600
|
||||
* if they won by eliminating the enemy team. */
|
||||
Rules_RoundOver(winner, 3600, FALSE);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -45,7 +45,7 @@ void Timer_Update(void)
|
|||
fGameTime = -1;
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
// This map has been played enough we think
|
||||
if (fGameState != GAME_OVER) {
|
||||
if (cvar("mp_timelimit") > 0) {
|
||||
|
@ -106,6 +106,7 @@ void Timer_Update(void)
|
|||
if (fGameTime <= 0) {
|
||||
if (iWon_T == 0 && iWon_CT == 0) {
|
||||
Money_ResetTeamReward();
|
||||
Money_ResetRoundReward();
|
||||
Rules_Restart(TRUE);
|
||||
} else {
|
||||
if (autocvar_mp_halftime == TRUE && (autocvar_mp_winlimit / 2 == iRounds)) {
|
||||
|
|
|
@ -67,7 +67,9 @@ static void WeaponC4BOMB_Use( void ) {
|
|||
// Takes 10 seconds to defuse that thing!
|
||||
if ( fDefuseProgress > 10 ) {
|
||||
sound( self, CHAN_VOICE, "weapons/c4_disarmed.wav", 1.0, ATTN_NORM );
|
||||
Rules_RoundOver( TEAM_CT, 3500, TRUE );
|
||||
/* In Bomb Defusal, all Counter-Terrorists receive $3600 if
|
||||
* they won by defusing the bomb. */
|
||||
Rules_RoundOver( TEAM_CT, 3600, TRUE );
|
||||
Radio_BroadcastMessage( RADIO_BOMBDEF );
|
||||
eActivator.fProgressBar = 0;
|
||||
iBombPlanted = FALSE;
|
||||
|
@ -100,7 +102,8 @@ static void WeaponC4BOMB_Think( void ) {
|
|||
|
||||
// If our time has passed, explode
|
||||
if ( self.fAttackFinished < time ) {
|
||||
// Terrorists win
|
||||
/* In Bomb Defusal, all Terrorists receive $3500
|
||||
* if they won by detonating the bomb. */
|
||||
Rules_RoundOver( TEAM_T, 3500, FALSE );
|
||||
|
||||
// Make it explode and hurt things
|
||||
|
|
|
@ -142,6 +142,7 @@ void WeaponFLASHBANG_Throw( void ) {
|
|||
eNade.nextthink = time + 3.0f;
|
||||
|
||||
self.iAmmo_FLASHBANG--;
|
||||
Radio_TeamMessage(RADIO_CT_FIREINHOLE, self.team);
|
||||
|
||||
if ( !self.iAmmo_FLASHBANG ) {
|
||||
Weapon_SwitchBest();
|
||||
|
|
|
@ -125,6 +125,8 @@ void WeaponHEGRENADE_Throw( void ) {
|
|||
|
||||
self.iAmmo_HEGRENADE--;
|
||||
|
||||
Radio_TeamMessage(RADIO_CT_FIREINHOLE, self.team);
|
||||
|
||||
if ( !self.iAmmo_HEGRENADE ) {
|
||||
Weapon_SwitchBest();
|
||||
} else {
|
||||
|
|
|
@ -116,22 +116,27 @@ void WeaponM3_Secondary( void ) {
|
|||
void WeaponM3_Reload( void ) {
|
||||
#ifdef SSQC
|
||||
// Can we reload the gun even if we wanted to?
|
||||
if ( ( self.(wptM3.iMagfld) != wptM3.iMagSize ) && ( self.(wptM3.iCaliberfld) > 0 ) ) {
|
||||
self.iMode_M3 = 1 - self.iMode_M3;
|
||||
|
||||
if ( self.iMode_M3 == TRUE ) {
|
||||
self.think = WeaponM3_Secondary;
|
||||
self.nextthink = time + 0.8;
|
||||
} else {
|
||||
self.think = WeaponM3_ReloadNULL;
|
||||
}
|
||||
|
||||
Client_SendEvent( self, EV_WEAPON_RELOAD );
|
||||
self.fAttackFinished = time + 1.0;
|
||||
if (( self.(wptM3.iMagfld) == wptM3.iMagSize )) {
|
||||
return;
|
||||
}
|
||||
if (self.(wptM3.iCaliberfld) <= 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
self.iMode_M3 = 1 - self.iMode_M3;
|
||||
|
||||
if (self.iMode_M3) {
|
||||
self.think = WeaponM3_Secondary;
|
||||
self.nextthink = time + 0.8;
|
||||
} else {
|
||||
self.think = WeaponM3_ReloadNULL;
|
||||
}
|
||||
|
||||
Client_SendEvent( self, EV_WEAPON_RELOAD );
|
||||
self.fAttackFinished = time + 1.0;
|
||||
#else
|
||||
iWeaponMode_M3 = 1 - iWeaponMode_M3;
|
||||
|
||||
|
||||
if ( iWeaponMode_M3 == TRUE ) {
|
||||
View_PlayAnimation( ANIM_M3_RELOAD_START );
|
||||
} else {
|
||||
|
|
|
@ -239,8 +239,15 @@ void Weapon_Release( void ) {
|
|||
} else if ( self.weapon == WEAPON_C4BOMB ) {
|
||||
WeaponC4BOMB_Release();
|
||||
} else {
|
||||
if (self.(wptTable[ self.weapon ].iMagfld) == 0 && self.(wptTable[ self.weapon ].iCaliberfld)) {
|
||||
Weapon_Reload(self.weapon);
|
||||
if (self.weapon == WEAPON_XM1014) {
|
||||
return;
|
||||
} else if (self.weapon == WEAPON_M3) {
|
||||
return;
|
||||
}
|
||||
if (self.(wptTable[ self.weapon ].iMagfld) <= 0) {
|
||||
if (self.(wptTable[ self.weapon ].iCaliberfld)) {
|
||||
Weapon_Reload(self.weapon);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -132,6 +132,7 @@ void WeaponSMOKEGRENADE_Throw( void ) {
|
|||
eNade.gravity = 0.5f;
|
||||
|
||||
self.iAmmo_SMOKEGRENADE--;
|
||||
Radio_TeamMessage(RADIO_CT_FIREINHOLE, self.team);
|
||||
|
||||
if ( !self.iAmmo_SMOKEGRENADE ) {
|
||||
Weapon_SwitchBest();
|
||||
|
|
|
@ -114,19 +114,24 @@ void WeaponXM1014_Secondary( void ) {
|
|||
void WeaponXM1014_Reload( void ) {
|
||||
#ifdef SSQC
|
||||
// Can we reload the gun even if we wanted to?
|
||||
if ( ( self.(wptXM1014.iMagfld) != wptXM1014.iMagSize ) && ( self.(wptXM1014.iCaliberfld) > 0 ) ) {
|
||||
self.iMode_XM1014 = 1 - self.iMode_XM1014;
|
||||
|
||||
if ( self.iMode_XM1014 == TRUE ) {
|
||||
self.think = WeaponXM1014_Secondary;
|
||||
self.nextthink = time + 0.8;
|
||||
} else {
|
||||
self.think = WeaponXM1014_ReloadNULL;
|
||||
}
|
||||
|
||||
Client_SendEvent( self, EV_WEAPON_RELOAD );
|
||||
self.fAttackFinished = time + 0.5;
|
||||
if (self.(wptXM1014.iMagfld) == wptXM1014.iMagSize) {
|
||||
return;
|
||||
}
|
||||
if (self.(wptXM1014.iCaliberfld) <= 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
self.iMode_XM1014 = 1 - self.iMode_XM1014;
|
||||
|
||||
if ( self.iMode_XM1014 == TRUE ) {
|
||||
self.think = WeaponXM1014_Secondary;
|
||||
self.nextthink = time + 0.8;
|
||||
} else {
|
||||
self.think = WeaponXM1014_ReloadNULL;
|
||||
}
|
||||
|
||||
Client_SendEvent( self, EV_WEAPON_RELOAD );
|
||||
self.fAttackFinished = time + 0.5;
|
||||
#else
|
||||
iWeaponMode_XM1014 = 1 - iWeaponMode_XM1014;
|
||||
|
||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
Reference in a new issue