1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-06 09:09:40 +02:00

- Fixed special spells spawning in Pyramid

- Allowed new spells to spawn in Pyramid
This commit is contained in:
DjWarmonger
2014-03-09 12:33:26 +00:00
parent 0347c61dd2
commit 1d6e265e34
2 changed files with 8 additions and 3 deletions

View File

@@ -690,8 +690,8 @@ void CMapLoaderH3M::readAllowedArtifacts()
void CMapLoaderH3M::readAllowedSpellsAbilities()
{
// Read allowed spells
map->allowedSpell.resize(GameConstants::SPELLS_QUANTITY, true);
// Read allowed spells, including new ones
map->allowedSpell.resize(VLC->spellh->objects.size(), true);
// Read allowed abilities
map->allowedAbilities.resize(GameConstants::SKILL_QUANTITY, true);
@@ -706,6 +706,11 @@ void CMapLoaderH3M::readAllowedSpellsAbilities()
const int abil_bytes = 4;
readBitmask(map->allowedAbilities, abil_bytes, GameConstants::SKILL_QUANTITY);
}
//do not generate special abilities and spells
for (auto spell : VLC->spellh->objects)
if (spell->isSpecialSpell() || spell->isCreatureAbility())
map->allowedSpell[spell->id] = false;
}
void CMapLoaderH3M::readRumors()