mirror of
https://github.com/vcmi/vcmi.git
synced 2025-03-17 20:58:07 +02:00
Fixes Adrienne starting without Inferno spell in campaign
This commit is contained in:
parent
a092760237
commit
49138e3de9
@ -1866,7 +1866,12 @@ CGObjectInstance * CMapLoaderH3M::readHero(const int3 & mapPosition, const Objec
|
||||
//we can read one spell
|
||||
SpellID spell = reader->readSpell();
|
||||
|
||||
if(spell != SpellID::NONE)
|
||||
// workaround: VCMI uses 'PRESET' spell to indicate that spellbook has been preconfigured on map
|
||||
// but H3 uses 'PRESET' spell (-2) to indicate that game should give standard spell to hero
|
||||
if(spell == SpellID::NONE)
|
||||
object->spells.insert(SpellID::PRESET); //spellbook is preconfigured to be empty
|
||||
|
||||
if (spell.hasValue())
|
||||
object->spells.insert(spell);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user