1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-27 22:49:25 +02:00

Implemented configurable shrine

This commit is contained in:
Ivan Savenko
2023-10-04 16:49:17 +03:00
parent dd841bdaa7
commit bb05c2dea5
17 changed files with 36 additions and 531 deletions

View File

@@ -125,6 +125,12 @@ bool Rewardable::Limiter::heroAllowed(const CGHeroInstance * hero) const
return false;
}
for(const auto & spell : canLearnSpells)
{
if (!hero->canLearnSpell(spell.toSpell(VLC->spells())))
return false;
}
{
std::unordered_map<ArtifactID, unsigned int, ArtifactID::hash> artifactsRequirements; // artifact ID -> required count
for(const auto & art : artifacts)