mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-23 22:37:55 +02:00
support setting spell master level in OPENING_BATTLE_SPELLS
This commit is contained in:
@@ -206,7 +206,8 @@ void BattleFlowProcessor::castOpeningSpells(const CBattleInfoCallback & battle)
|
||||
const CSpell * spell = b->subtype.as<SpellID>().toSpell();
|
||||
|
||||
spells::BattleCast parameters(&battle, &caster, spells::Mode::PASSIVE, spell);
|
||||
parameters.setSpellLevel(3);
|
||||
int32_t spellLevel = b->additionalInfo != CAddInfo::NONE ? b->additionalInfo[0] : 3;
|
||||
parameters.setSpellLevel(spellLevel);
|
||||
parameters.setEffectDuration(b->val);
|
||||
parameters.massive = true;
|
||||
parameters.castIfPossible(gameHandler->spellcastEnvironment(), spells::Target());
|
||||
|
||||
Reference in New Issue
Block a user