mirror of
https://github.com/vcmi/vcmi.git
synced 2025-07-01 00:45:26 +02:00
some changes towards editing H3 objects via mods. Should be stable, report if not.
- removed duplicated json loading code in handlers - simpler and mod-friendly handling of combined artifacts - reorganized CCreature to avoid huge number of fields in one structure
This commit is contained in:
@ -740,7 +740,7 @@ void CGHeroInstance::initHero()
|
||||
else //remove placeholder
|
||||
spells -= SpellID::PRESET;
|
||||
|
||||
if(!getArt(ArtifactPosition::MACH4) && !getArt(ArtifactPosition::SPELLBOOK) && !type->spells.empty()) //no catapult means we haven't read pre-existent set -> use default rules for spellbook
|
||||
if(!getArt(ArtifactPosition::MACH4) && !getArt(ArtifactPosition::SPELLBOOK) && type->haveSpellBook) //no catapult means we haven't read pre-existent set -> use default rules for spellbook
|
||||
putArtifact(ArtifactPosition::SPELLBOOK, CArtifactInstance::createNewArtifactInstance(0));
|
||||
|
||||
if(!getArt(ArtifactPosition::MACH4))
|
||||
|
Reference in New Issue
Block a user