Added Autobandage option to Skill Menu.

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@9344 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
Sevenfm
2022-03-25 10:50:18 +00:00
parent 033ae4a191
commit 9acaa41e95
12 changed files with 56 additions and 6 deletions
+14 -1
View File
@@ -313,6 +313,9 @@ void HandleMouseTBMButton( UINT32 *puiNewEvent );
void HandleMouseTBX1Button( UINT32 *puiNewEvent );
void HandleMouseTBX2Button( UINT32 *puiNewEvent );
// sevenfm: check availability for actions
BOOLEAN CheckAutoBandage(void);
// sevenfm: common functionality
void HandleTBSelectAllMercs( void );
void HandleTBToggleStealthAll( void );
@@ -3290,7 +3293,7 @@ void GetKeyboardInput( UINT32 *puiNewEvent )
#else
//shadooow: trying to use autobandage during conversation will mess up game
// sevenfm: don't try to activate autobandage in hostile sector
if (!(gTacticalStatus.uiFlags & INCOMBAT) && NumEnemyInSector() == 0 && DialogueQueueIsEmpty())
if (CheckAutoBandage())
{
BeginAutoBandage();
}
@@ -9621,3 +9624,13 @@ void HandleTBSkillsMenu(void)
TraitsMenu(MercPtrs[gusSelectedSoldier]->sGridNo);
}
}
BOOLEAN CheckAutoBandage(void)
{
if (!(gTacticalStatus.uiFlags & INCOMBAT) && NumEnemyInSector() == 0 && DialogueQueueIsEmpty())
{
return TRUE;
}
return FALSE;
}