Skip to content

Commit

Permalink
vehicle damage scaling
Browse files Browse the repository at this point in the history
  • Loading branch information
videoP committed Jan 15, 2024
1 parent 09b8aae commit 0d6861c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion codemp/game/bg_slidemove.c
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,7 @@ void PM_VehicleImpact(bgEntity_t *pEnt, trace_t *trace)
if (pSelfVeh->m_pVehicleInfo->type == VH_FIGHTER)
{ //player die good.. if me fighter
if (g_tweakWeapons.integer & WT_TRIBES)
pmult = 7.0f;
pmult = 7.0f * g_weaponDamageScale.value;
else
pmult = 2000.0f;
}
Expand Down
2 changes: 1 addition & 1 deletion codemp/game/g_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -3919,7 +3919,7 @@ void G_RunFrame( int levelTime ) {
if (ent->client->jetPackDebReduce < level.time) //ent->client->jetPackDebReduce can be negative or 0 or ?
{
if (ent->client->pers.tribesClass == 3) //Heavy
ent->client->ps.fd.forcePower -= 7;
ent->client->ps.fd.forcePower -= 6;
if (ent->client->pers.tribesClass == 2) //Med
ent->client->ps.fd.forcePower -= 5;
else
Expand Down
8 changes: 4 additions & 4 deletions codemp/game/g_weapon.c
Original file line number Diff line number Diff line change
Expand Up @@ -498,8 +498,8 @@ void WP_FireTurboLaserMissile( gentity_t *ent, vec3_t start, vec3_t dir )
missile->classname = "turbo_proj";
missile->s.weapon = WP_TURRET;

missile->damage = ent->damage; //FIXME: externalize
missile->splashDamage = ent->splashDamage; //FIXME: externalize
missile->damage = ent->damage * g_weaponDamageScale.value; //FIXME: externalize
missile->splashDamage = ent->splashDamage * g_splashDamageScale.value; //FIXME: externalize
missile->splashRadius = ent->splashRadius; //FIXME: externalize
missile->dflags = DAMAGE_DEATH_KNOCKBACK;
missile->methodOfDeath = MOD_TURBLAST; //count as a heavy weap
Expand Down Expand Up @@ -5434,8 +5434,8 @@ gentity_t *WP_FireVehicleWeapon( gentity_t *ent, vec3_t start, vec3_t dir, vehWe
missile->classname = "vehicle_proj";

missile->s.genericenemyindex = ent->s.number+MAX_GENTITIES;
missile->damage = vehWeapon->iDamage;
missile->splashDamage = vehWeapon->iSplashDamage;
missile->damage = vehWeapon->iDamage * g_weaponDamageScale.value;
missile->splashDamage = vehWeapon->iSplashDamage * g_splashDamageScale.value;
missile->splashRadius = vehWeapon->fSplashRadius;

//FIXME: externalize some of these properties?
Expand Down

0 comments on commit 0d6861c

Please sign in to comment.