1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-06 09:09:40 +02:00

get rid of CBattleInfoCallback::battleCanCastThisSpell

This commit is contained in:
AlexVinS
2017-06-05 23:46:55 +03:00
parent 6c308956f9
commit 195e979a18
7 changed files with 30 additions and 44 deletions

View File

@@ -549,7 +549,7 @@ void CSpellWindow::SpellArea::clickLeft(tribool down, bool previousState)
//we will cast a spell
if(mySpell->isCombatSpell() && owner->myInt->battleInt) //if battle window is open
{
ESpellCastProblem::ESpellCastProblem problem = owner->myInt->cb->battleCanCastThisSpell(owner->myHero, mySpell, ECastingMode::HERO_CASTING);
ESpellCastProblem::ESpellCastProblem problem = mySpell->canBeCast(owner->myInt->cb.get(), ECastingMode::HERO_CASTING, owner->myHero);
switch (problem)
{
case ESpellCastProblem::OK: