1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-07-15 01:24:45 +02:00

- Config settings & parsing for Commanders.

- Fix for Regeneration icon
This commit is contained in:
DjWarmonger
2012-04-22 13:28:46 +00:00
parent 017013a5a4
commit 81e74f8c33
7 changed files with 128 additions and 15 deletions

View File

@ -3005,7 +3005,7 @@ void CBattleInterface::handleHex(BattleHex myNumber, int eventType)
bool CBattleInterface::isCastingPossibleHere (const CStack * sactive, const CStack * shere, BattleHex myNumber)
{
creatureCasting = stackCanCastSpell; //is it really useful?
creatureCasting = stackCanCastSpell && !spellDestSelectMode; //TODO: allow creatures to cast aimed spells
bool isCastingPossible = true;
@ -3022,7 +3022,7 @@ bool CBattleInterface::isCastingPossibleHere (const CStack * sactive, const CSta
if (spellID >= 0)
sp = CGI->spellh->spells[spellID];
if (sp) //TODO: refactor?
if (sp)
{
if (creatureCasting)
isCastingPossible = (curInt->cb->battleCanCreatureCastThisSpell (sp, myNumber) == ESpellCastProblem::OK);