mirror of
https://github.com/1dot13/source.git
synced 2026-08-12 14:10:23 +02:00
Added Headrock's HAM 2.8
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@2650 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -30,6 +30,8 @@
|
||||
#include "Text.h"
|
||||
#include "strategicmap.h"
|
||||
#include "Render Fun.h"
|
||||
// HEADROCK HAM B2.7: Allow calling a CTH approximation function for the CTH display ("F" key)
|
||||
#include "UI Cursors.h"
|
||||
#endif
|
||||
|
||||
|
||||
@@ -635,7 +637,12 @@ void DisplayRangeToTarget( SOLDIERTYPE *pSoldier, INT16 sTargetGridNo )
|
||||
//AXP 30.03.2007: Fix CtH calculation for first shot after changing aim level (roof/ground)
|
||||
INT8 bTempTargetLevel = pSoldier->bTargetLevel;
|
||||
pSoldier->bTargetLevel = (INT8)gsInterfaceLevel;
|
||||
uiHitChance = CalcChanceToHitGun( pSoldier, sTargetGridNo, (pSoldier->aiData.bShownAimTime ), pSoldier->bAimShotLocation );
|
||||
uiHitChance = CalcChanceToHitGun( pSoldier, sTargetGridNo, (INT8)(pSoldier->aiData.bShownAimTime ), pSoldier->bAimShotLocation );
|
||||
// HEADROCK HAM B2.7: CTH approximation?
|
||||
if (gGameExternalOptions.fApproximateCTH)
|
||||
{
|
||||
uiHitChance = ChanceToHitApproximation( pSoldier, uiHitChance );
|
||||
}
|
||||
pSoldier->bTargetLevel = bTempTargetLevel;
|
||||
|
||||
swprintf( zOutputString, zNewTacticalMessages[ TCTL_MSG__GUN_RANGE_AND_CTH ], Weapon[ pSoldier->inv[HANDPOS].usItem ].usRange / 10, uiHitChance );
|
||||
|
||||
Reference in New Issue
Block a user