mirror of
https://github.com/yquake2/rogue.git
synced 2024-11-22 04:11:25 +00:00
ETF Rifle respects infinite ammo DM flag
This commit is contained in:
parent
bd6fc9df5f
commit
66da1722ca
1 changed files with 5 additions and 19 deletions
|
@ -2268,7 +2268,7 @@ weapon_etf_rifle_fire(edict_t *ent)
|
|||
{
|
||||
vec3_t forward, right, up;
|
||||
vec3_t start, tempPt;
|
||||
int damage;
|
||||
int damage = 10;
|
||||
int kick = 3;
|
||||
int i;
|
||||
vec3_t offset;
|
||||
|
@ -2278,15 +2278,6 @@ weapon_etf_rifle_fire(edict_t *ent)
|
|||
return;
|
||||
}
|
||||
|
||||
if (deathmatch->value)
|
||||
{
|
||||
damage = 10;
|
||||
}
|
||||
else
|
||||
{
|
||||
damage = 10;
|
||||
}
|
||||
|
||||
if (ent->client->pers.inventory[ent->client->ammo_index] < ent->client->pers.weapon->quantity)
|
||||
{
|
||||
VectorClear(ent->client->kick_origin);
|
||||
|
@ -2341,7 +2332,9 @@ weapon_etf_rifle_fire(edict_t *ent)
|
|||
PlayerNoise(ent, start, PNOISE_WEAPON);
|
||||
|
||||
ent->client->ps.gunframe++;
|
||||
ent->client->pers.inventory[ent->client->ammo_index] -= ent->client->pers.weapon->quantity;
|
||||
|
||||
if (!((int)dmflags->value & DF_INFINITE_AMMO))
|
||||
ent->client->pers.inventory[ent->client->ammo_index] -= ent->client->pers.weapon->quantity;
|
||||
|
||||
ent->client->anim_priority = ANIM_ATTACK;
|
||||
|
||||
|
@ -2403,18 +2396,11 @@ Heatbeam_Fire(edict_t *ent)
|
|||
if (deathmatch->value)
|
||||
{
|
||||
damage = HEATBEAM_DM_DMG;
|
||||
kick = 75; /* really knock 'em around in deathmatch */
|
||||
}
|
||||
else
|
||||
{
|
||||
damage = HEATBEAM_SP_DMG;
|
||||
}
|
||||
|
||||
if (deathmatch->value) /* really knock 'em around in deathmatch */
|
||||
{
|
||||
kick = 75;
|
||||
}
|
||||
else
|
||||
{
|
||||
kick = 30;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue