Fix: During Autoresolve a group that was in the sector could be assigned again as reinforcement which practically cloned the soldiers. Groups that are in the battle sector already now will not be considered as reinforcement anymore.

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7636 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
silversurfer
2014-11-02 13:41:18 +00:00
parent 7a61eec3e0
commit d4b6b6f4a7
+4 -2
View File
@@ -105,8 +105,10 @@ BOOLEAN IsGroupInARightSectorToReinforce( GROUP *pGroup, INT16 sSectorX, INT16 s
UINT16 pusMoveDir[4][3];
UINT8 ubDirNumber = 0, ubIndex;
if( pGroup->ubSectorX == sSectorX && pGroup->ubSectorY == sSectorY )
return TRUE; //Well, it's in the same sector, so allow to reinforce
// silversurfer: A group that is already in the right sector is not reinforcement. It's either stationary or mobile. Reinforcements have to come from different sectors.
// If we allow groups here that are already in the sector we will assign them twice (stationary/mobile + reinforcement)! Not good.
/* if( pGroup->ubSectorX == sSectorX && pGroup->ubSectorY == sSectorY )
return TRUE; //Well, it's in the same sector, so allow to reinforce*/
if( !gGameExternalOptions.gfAllowReinforcements )
return FALSE;