1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-09-16 09:26:28 +02:00

Fix Solmyr/Yog receiving spellbook on transferring to next scenario

This commit is contained in:
Ivan Savenko
2025-07-31 21:54:56 +03:00
parent 03997a800a
commit 800ccf2651

View File

@@ -197,6 +197,10 @@ void CGameStateCampaign::trimCrossoverHeroesParameters(vstd::RNG & randomGenerat
hero.hero->eraseStack(slotID);
}
// Add spell flag to ensure that hero without spellbook won't receive one as part of initHero call
for(auto & hero : campaignHeroReplacements)
hero.hero->addSpellToSpellbook(SpellID::SPELLBOOK_PRESET);
// Removing short-term bonuses
for(auto & hero : campaignHeroReplacements)
{