diff options
author | Michael Levin <risujin@fastmail.fm> | 2009-10-03 11:14:57 +0000 |
---|---|---|
committer | Tim Angus <tim@ngus.net> | 2013-01-03 00:14:47 +0000 |
commit | b4d3fc69f691cbe19cecf0f3c99e8eed64dc3ddf (patch) | |
tree | 7c60d559a322c2a72b215a7b70274e60e33e3baf /src | |
parent | b6ce8f15e93332e5da2f335905ffe06a1cf8e97f (diff) |
* Damage regions are no longer included in non-locational damage
calculations
* Light armour angles reverted to 100/80/100/80
* Norfenstein's balance changes for Dretch HP which got lost before
somehow
Diffstat (limited to 'src')
-rw-r--r-- | src/game/g_combat.c | 18 | ||||
-rw-r--r-- | src/game/tremulous.h | 2 |
2 files changed, 11 insertions, 9 deletions
diff --git a/src/game/g_combat.c b/src/game/g_combat.c index 7a339f56..1dedb88b 100644 --- a/src/game/g_combat.c +++ b/src/game/g_combat.c @@ -736,9 +736,10 @@ static float GetDamageRegionModifier( gentity_t *targ, damageRegion_t *regions, { // Angle must be within range if( ( regions[ i ].minAngle <= regions[ i ].maxAngle && - ( angle < regions[ i ].minAngle || angle > regions[ i ].maxAngle ) || + ( angle < regions[ i ].minAngle || + angle > regions[ i ].maxAngle ) ) || ( regions[ i ].minAngle > regions[ i ].maxAngle && - angle > regions[ i ].maxAngle && angle < regions[ i ].minAngle ) ) ) + angle > regions[ i ].maxAngle && angle < regions[ i ].minAngle ) ) continue; // Height must be within range @@ -753,7 +754,8 @@ static float GetDamageRegionModifier( gentity_t *targ, damageRegion_t *regions, } if( g_debugDamage.integer ) - G_Printf( "GetDamageRegionModifier(): %f\n", modifier ); + G_Printf( "GetDamageRegionModifier(angle = %f, height = %f): %f\n", + angle, height, modifier ); return modifier; } @@ -797,11 +799,11 @@ static float G_CalcDamageModifier( vec3_t point, gentity_t *targ, gentity_t *att if( hitRotation < 0.f ) hitRotation += 360.f; - // Get modifiers from the target's armour and damage regions + // Get modifiers from the target's damage regions if( dflags & DAMAGE_NO_LOCDAMAGE ) { - modifier = GetNonLocDamageModifier( targ, g_damageRegions[ class ], - g_numDamageRegions[ class ] ); + // Non-locational damage only uses armour regions + modifier = 1.0f; for( i = UP_NONE + 1; i < UP_NUM_UPGRADES; i++ ) { if( BG_InventoryContainsUpgrade( i, targ->client->ps.stats ) ) @@ -814,8 +816,8 @@ static float G_CalcDamageModifier( vec3_t point, gentity_t *targ, gentity_t *att else { modifier = GetDamageRegionModifier( targ, g_damageRegions[ class ], - g_numDamageRegions[ class ], - hitRotation, hitRatio ); + g_numDamageRegions[ class ], + hitRotation, hitRatio ); for( i = UP_NONE + 1; i < UP_NUM_UPGRADES; i++ ) { if( BG_InventoryContainsUpgrade( i, targ->client->ps.stats ) ) diff --git a/src/game/tremulous.h b/src/game/tremulous.h index 311db017..2e8568d1 100644 --- a/src/game/tremulous.h +++ b/src/game/tremulous.h @@ -168,7 +168,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA #define LEVEL0_SPEED 1.3f #define LEVEL0_VALUE AVM(175) -#define LEVEL0_HEALTH AHM(25) +#define LEVEL0_HEALTH AHM(20) #define LEVEL0_REGEN 1 #define LEVEL0_COST 0 |