summaryrefslogtreecommitdiff
path: root/src/game/g_weapon.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/g_weapon.c')
-rw-r--r--src/game/g_weapon.c17
1 files changed, 14 insertions, 3 deletions
diff --git a/src/game/g_weapon.c b/src/game/g_weapon.c
index a9e04e6..4da6205 100644
--- a/src/game/g_weapon.c
+++ b/src/game/g_weapon.c
@@ -701,7 +701,8 @@ void teslaFire( gentity_t *ent )
if( !traceEnt->client )
return;
- if( traceEnt->client && traceEnt->client->ps.stats[ STAT_PTEAM ] != PTE_ALIENS )
+ if( traceEnt->client && traceEnt->client->ps.stats[ STAT_PTEAM ] != PTE_ALIENS &&
+ !traceEnt->client->pers.bleeder )
return;
//so the client side knows
@@ -709,8 +710,13 @@ void teslaFire( gentity_t *ent )
if( traceEnt->takedamage )
{
+ int dmg = TESLAGEN_DMG;
+
+ if( g_modStage3Strength.integer > 0 )
+ dmg = dmg * g_modStage3Strength.integer / 100;
+
G_Damage( traceEnt, ent, ent, forward, tr.endpos,
- TESLAGEN_DMG, 0, MOD_TESLAGEN );
+ dmg, 0, MOD_TESLAGEN );
}
// snap the endpos to integers to save net bandwidth, but nudged towards the line
@@ -781,6 +787,7 @@ void cancelBuildFire( gentity_t *ent )
traceEnt->health += HBUILD_HEALRATE;
ent->client->pers.statscounters.repairspoisons++;
+ ent->client->pers.karma += 1;
level.humanStatsCounters.repairspoisons++;
if( traceEnt->health > bHealth )
@@ -814,7 +821,7 @@ void buildFire( gentity_t *ent, dynMenu_t menu )
if( G_BuildIfValid( ent, ent->client->ps.stats[ STAT_BUILDABLE ] & ~SB_VALID_TOGGLEBIT ) )
{
- if( g_cheats.integer )
+ if( g_cheats.integer || g_instantBuild.integer )
{
ent->client->ps.stats[ STAT_MISC ] = 0;
}
@@ -1184,6 +1191,8 @@ static void G_CreateNewZap( gentity_t *creator, gentity_t *target )
zap->used = qtrue;
zap->timeToLive = LEVEL2_AREAZAP_TIME;
+ if( g_modAlienRate.integer > 0 )
+ zap->timeToLive = zap->timeToLive * g_modAlienRate.integer / 100;
zap->damageUsed = 0;
zap->creator = creator;
@@ -1277,6 +1286,8 @@ void G_UpdateZaps( int msec )
{
G_Damage( target, source, zap->creator, forward, target->s.origin,
damage, DAMAGE_NO_KNOCKBACK | DAMAGE_NO_LOCDAMAGE, MOD_LEVEL2_ZAP );
+ if( g_modAlienRate.integer > 0 )
+ damage = damage * 100 / g_modAlienRate.integer;
zap->damageUsed += damage;
}
}