From f835b0459838f4b65a1d59a04ea9b4a4ddc5c924 Mon Sep 17 00:00:00 2001 From: Flugente Date: Thu, 25 Jul 2013 17:30:48 +0000 Subject: [PATCH] spies lose cover if they try to handcuff but fail git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6241 3b4a5df2-a311-0410-b5c6-a8a6f20db521 --- Tactical/Soldier Control.cpp | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/Tactical/Soldier Control.cpp b/Tactical/Soldier Control.cpp index 5aab05cd1..c8d5a974f 100644 --- a/Tactical/Soldier Control.cpp +++ b/Tactical/Soldier Control.cpp @@ -17475,6 +17475,21 @@ void SOLDIERTYPE::EVENT_SoldierHandcuffPerson( INT32 sGridNo, UINT8 ubDirection // curses! this->DoMercBattleSound( BATTLE_SOUND_CURSE1 ); + + // if we are disguised, there is a chance that he'll uncover us + if ( this->bSoldierFlagMask & (SOLDIER_COVERT_CIV|SOLDIER_COVERT_SOLDIER) ) + { + this->LooseDisguise(); + this->Strip(); + + ScreenMsg( FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, szCovertTextStr[STR_COVERT_ACTIVITIES], this->GetName() ); + ScreenMsg( FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, szCovertTextStr[STR_COVERT_UNCOVERED], pSoldier->GetName(), this->GetName() ); + + // alert the soldier + pSoldier->aiData.bAlertStatus = min(pSoldier->aiData.bAlertStatus, STATUS_RED); + + ProcessImplicationsOfPCAttack( this, &pSoldier, REASON_NORMAL_ATTACK ); + } } } else