added and adjusted the following features by zwwooooo to help restoring IoV to a pure item mod:

- externalized the brightness vision range modifiers to allow for different ratios of day/night vision range
- added <PercentRangeBonus> as a complement to <Rangebonus>
- added the possibility for LBE vests to function as plate carriers

These were the missing features from IoV previously not in the 1.13 trunk. Thereby, IoV is now fully compatible to the current trunk (by DepressivesBrot)

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6279 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
Flugente
2013-08-08 21:08:04 +00:00
parent a543b33c4b
commit fd8b146296
11 changed files with 195 additions and 16 deletions
+2 -1
View File
@@ -8299,7 +8299,8 @@ FLOAT CalcBulletDeviation( SOLDIERTYPE *pShooter, FLOAT *dShotOffsetX, FLOAT *dS
OBJECTTYPE* pObjAttHand = pShooter->GetUsedWeapon( &pShooter->inv[ pShooter->ubAttackingHand ] );
INT16 sAccuracy = GetGunAccuracy( pWeapon );
UINT16 sEffRange = Weapon[Item[pObjAttHand->usItem].ubClassIndex].usRange + GetRangeBonus( pObjAttHand );
UINT16 sEffRange = (Weapon[Item[pObjAttHand->usItem].ubClassIndex].usRange *GetPercentRangeBonus(pObjAttHand)) / 10000;
sEffRange += GetRangeBonus( pObjAttHand );
// WANNE: I got a CTD in a multiplayer test game, because sEffRange was 0 (division to zero).
// I don't know why this happend?