From 3341992db4d2ed9530b97bec534a68f14a9b1615 Mon Sep 17 00:00:00 2001 From: Wanne Date: Fri, 28 Mar 2014 19:50:24 +0000 Subject: [PATCH] Merged from revision: 7120 - Disabled militia assignment popup window when battle occurs for hostile sectors adjacent to associated town to prevent radio operator exploits (by Buggler) git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7121 3b4a5df2-a311-0410-b5c6-a8a6f20db521 --- Strategic/Map Screen Interface Map.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Strategic/Map Screen Interface Map.cpp b/Strategic/Map Screen Interface Map.cpp index 96028131..06c86715 100644 --- a/Strategic/Map Screen Interface Map.cpp +++ b/Strategic/Map Screen Interface Map.cpp @@ -7126,6 +7126,12 @@ BOOLEAN CanRedistributeMilitiaInSector( INT16 sClickedSectorX, INT16 sClickedSec // the fight is within this town! Can't redistribute. return( FALSE ); } + // to prevent radio operator exploits for hostile sectors adjacent to towns + else if ( ( sSectorX == gWorldSectorX && sSectorY == gWorldSectorY + 1 ) || ( sSectorX == gWorldSectorX + 1 && sSectorY == gWorldSectorY ) || + ( sSectorX == gWorldSectorX - 1 && sSectorY == gWorldSectorY ) || ( sSectorX == gWorldSectorX && sSectorY == gWorldSectorY - 1 ) ) + { + return( FALSE ); + } }