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

Spell cast logging refactored.

This commit is contained in:
AlexVinS
2016-09-17 23:04:23 +03:00
parent d993710f8e
commit 53fbf88316
7 changed files with 53 additions and 45 deletions

View File

@ -1249,6 +1249,14 @@ void CStack::getCasterName(MetaString & text) const
text.addReplacement(MetaString::CRE_PL_NAMES, type->idNumber.num);
}
void CStack::getCastDescription(const CSpell * spell, const std::vector<const CStack*> & attacked, MetaString & text) const
{
text.addTxt(MetaString::GENERAL_TXT, 565);//The %s casts %s
//todo: use text 566 for single creature
getCasterName(text);
text.addReplacement(MetaString::SPELL_NAME, spell->id.toEnum());
}
bool CMP_stack::operator()( const CStack* a, const CStack* b )
{
switch(phase)