Merged from revision: 7077

More visual enemy gear info (by Sevenfm)
- Show additional info in NCTH cursor (press ALT) (ADDITIONAL_NCTH_CURSOR_INFO = 2)
-> You can only use this feature at certain distance
- Updated 'show enemy weapon' feature (SHOW_ENEMY_WEAPON = TRUE, SHOW_ENEMY_EXTENDED_INFO = TRUE)
- Now it can show armour and face items, too. Useful for OCTH users (SHOW_ENEMY_AWARENESS = TRUE)
- Show total value of damage, absorbed by armour in last attack (SHOW_HIT_INFO = TRUE)

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7078 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
Wanne
2014-03-16 19:34:16 +00:00
parent 072bd37325
commit 815c44d439
11 changed files with 396 additions and 135 deletions
+11 -2
View File
@@ -9343,6 +9343,8 @@ INT32 BulletImpact( SOLDIERTYPE *pFirer, BULLET *pBullet, SOLDIERTYPE * pTarget,
UINT16 usAttackingWeapon = 0;
INT32 sOrigGridNo = 0;
BOOLEAN fFragment = FALSE;
INT32 iTotalArmourProtection=0;
if (pBullet == NULL && pFirer )
{
usAttackingWeapon = pFirer->inv[pFirer->ubAttackingHand][0]->data.gun.ubGunAmmoType;
@@ -9413,7 +9415,7 @@ INT32 BulletImpact( SOLDIERTYPE *pFirer, BULLET *pBullet, SOLDIERTYPE * pTarget,
// up to 50% extra impact for making particularly accurate successful shots
iBonus = sHitBy / 2;
//NumMessage("Bonus = ",bonus);
//NumMessage("Bonus = ",bonus);
iOrigImpact = iOrigImpact * (100 + iFluke + iBonus) / 100;
@@ -9436,13 +9438,20 @@ INT32 BulletImpact( SOLDIERTYPE *pFirer, BULLET *pBullet, SOLDIERTYPE * pTarget,
}
}
// sevenfm: store original impact
pTarget->iLastBulletImpact += iOrigImpact;
if (pubSpecial && (*pubSpecial == FIRE_WEAPON_BLINDED_BY_SPIT_SPECIAL || *pubSpecial == FIRE_WEAPON_BLINDED_SPECIAL) )
{
iImpact = iOrigImpact;
}
else
{
iImpact = iOrigImpact - TotalArmourProtection( pTarget, ubHitLocation, iOrigImpact, ubAmmoType );
iTotalArmourProtection = TotalArmourProtection( pTarget, ubHitLocation, iOrigImpact, ubAmmoType );
iImpact = iOrigImpact - iTotalArmourProtection;
// sevenfm: store armour protection
pTarget->iLastArmourProtection += iTotalArmourProtection;
}
// calc minimum damage