mirror of
https://github.com/1dot13/source.git
synced 2026-08-05 14:00:23 +02:00
Brief: //dnl ch58
- Fix several problems which lead into bad or no AI decisions, add optional decision of short autofire. Details: - Avoid use of last two locations per turn - Fix problems with improper APs calculations for burst and autofire which lead into AI to forcably cancel and end turn for those actions. - Add option for decide to use short autofire instead of one long to enchance chance to hit. - After taking cover change facing toward closest enemy to avoid going in status red and rather take proper black decisions. - Fix bad public noise processing after AI investigate closest disturbance and find nothing, also erase all same noise points in team members if one of them already investigated. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6310 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -7351,7 +7351,7 @@ UINT32 CalcChanceToHitGun(SOLDIERTYPE *pSoldier, INT32 sGridNo, INT16 ubAimTime,
|
||||
iChance = gGameExternalOptions.ubMinimumCTH;
|
||||
if ( gGameExternalOptions.ubMinimumCTH == 0 )
|
||||
{
|
||||
if ( PreRandom( gGameExternalOptions.usMinimumCTHDivisor ) == (gGameExternalOptions.usMinimumCTHDivisor - 1) )
|
||||
if ( PreRandom( gGameExternalOptions.usMinimumCTHDivisor ) == (gGameExternalOptions.usMinimumCTHDivisor - 1) && fCalculateCTHDuringGunfire == TRUE )//dnl ch58 271009 Any Random function must not be used during calculation, only allow when you actually FireGun because AI became confused and sometimes do nothing
|
||||
{
|
||||
iChance = 1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user