mirror of
https://github.com/vcmi/vcmi.git
synced 2025-01-24 03:47:18 +02:00
Do not display "Spell Cancelled" message on right-click when no stack is
active
This commit is contained in:
parent
f2e7791326
commit
e21e3f8386
@ -999,7 +999,7 @@ void BattleActionsController::onHexRightClicked(BattleHex clickedHex)
|
||||
return action.spellcast();
|
||||
};
|
||||
|
||||
bool isCurrentStackInSpellcastMode = std::all_of(possibleActions.begin(), possibleActions.end(), spellcastActionPredicate);
|
||||
bool isCurrentStackInSpellcastMode = !possibleActions.empty() && std::all_of(possibleActions.begin(), possibleActions.end(), spellcastActionPredicate);
|
||||
|
||||
if (spellcastingModeActive() || isCurrentStackInSpellcastMode)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user