|
|
@@ -89,6 +89,7 @@ void BattleWindow::createQueue()
|
|
|
|
|
|
//create stack queue and adjust our own position
|
|
|
bool embedQueue;
|
|
|
+ bool showQueue = settings["battle"]["showQueue"].Bool();
|
|
|
std::string queueSize = settings["battle"]["queueSize"].String();
|
|
|
|
|
|
if(queueSize == "auto")
|
|
|
@@ -97,13 +98,16 @@ void BattleWindow::createQueue()
|
|
|
embedQueue = GH.screenDimensions().y < 700 || queueSize == "small";
|
|
|
|
|
|
queue = std::make_shared<StackQueue>(embedQueue, owner);
|
|
|
- if(!embedQueue && settings["battle"]["showQueue"].Bool())
|
|
|
+ if(!embedQueue && showQueue)
|
|
|
{
|
|
|
//re-center, taking into account stack queue position
|
|
|
pos.y -= queue->pos.h;
|
|
|
pos.h += queue->pos.h;
|
|
|
pos = center();
|
|
|
}
|
|
|
+
|
|
|
+ if (!showQueue)
|
|
|
+ queue->disable();
|
|
|
}
|
|
|
|
|
|
BattleWindow::~BattleWindow()
|
|
|
@@ -143,8 +147,8 @@ void BattleWindow::hideQueue()
|
|
|
pos.y += queue->pos.h;
|
|
|
pos.h -= queue->pos.h;
|
|
|
pos = center();
|
|
|
- GH.totalRedraw();
|
|
|
}
|
|
|
+ GH.totalRedraw();
|
|
|
}
|
|
|
|
|
|
void BattleWindow::showQueue()
|
|
|
@@ -213,9 +217,12 @@ void BattleWindow::tacticPhaseStarted()
|
|
|
auto menuTactics = widget<CIntObject>("menuTactics");
|
|
|
auto tacticNext = widget<CIntObject>("tacticNext");
|
|
|
auto tacticEnd = widget<CIntObject>("tacticEnd");
|
|
|
+ auto alternativeAction = widget<CIntObject>("alternativeAction");
|
|
|
|
|
|
menuBattle->disable();
|
|
|
console->disable();
|
|
|
+ if (alternativeAction)
|
|
|
+ alternativeAction->disable();
|
|
|
|
|
|
menuTactics->enable();
|
|
|
tacticNext->enable();
|
|
|
@@ -231,9 +238,12 @@ void BattleWindow::tacticPhaseEnded()
|
|
|
auto menuTactics = widget<CIntObject>("menuTactics");
|
|
|
auto tacticNext = widget<CIntObject>("tacticNext");
|
|
|
auto tacticEnd = widget<CIntObject>("tacticEnd");
|
|
|
+ auto alternativeAction = widget<CIntObject>("alternativeAction");
|
|
|
|
|
|
menuBattle->enable();
|
|
|
console->enable();
|
|
|
+ if (alternativeAction)
|
|
|
+ alternativeAction->enable();
|
|
|
|
|
|
menuTactics->disable();
|
|
|
tacticNext->disable();
|