1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-07-07 00:58:39 +02:00

[Spells] More spell related refactoring

+ smart target modifier
- CREATURE_EXPERT_MASSIVE target type
* save format changed

spell format changes already documented in http://wiki.vcmi.eu/index.php?title=Spell_Format
This commit is contained in:
alexvins
2014-03-17 13:11:10 +00:00
parent 7f6f125b4c
commit 9cac0af7be
11 changed files with 806 additions and 551 deletions

View File

@ -630,7 +630,7 @@ void CSpellWindow::SpellArea::clickLeft(tribool down, bool previousState)
|| (!sp->combatSpell && owner->myInt->battleInt))
{
std::vector<CComponent*> hlp(1, new CComponent(CComponent::spell, mySpell, 0));
LOCPLINT->showInfoDialog(sp->descriptions[schoolLevel], hlp);
LOCPLINT->showInfoDialog(sp->getLevelInfo(schoolLevel).description, hlp);
return;
}
@ -810,7 +810,7 @@ void CSpellWindow::SpellArea::clickRight(tribool down, bool previousState)
boost::algorithm::replace_first(dmgInfo, "%d", boost::lexical_cast<std::string>(causedDmg));
}
CRClickPopup::createAndPush(CGI->spellh->objects[mySpell]->descriptions[schoolLevel] + dmgInfo,
CRClickPopup::createAndPush(CGI->spellh->objects[mySpell]->getLevelInfo(schoolLevel).description + dmgInfo,
new CComponent(CComponent::spell, mySpell));
}
}