1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-06-17 00:07:41 +02:00

vcmi: remove ALL_CREATURES propagator

Now unneded, because it handled by GLOBAL_EFFECT with
CREATURE_LEVEL_LIMITER (when range set to UINT_MIN and UINT_MAX).
This commit is contained in:
Konstantin
2023-04-06 20:03:17 +03:00
parent 9f8dcfc736
commit f8eba58003
7 changed files with 23 additions and 23 deletions

View File

@ -754,7 +754,7 @@ std::shared_ptr<ILimiter> JsonUtils::parseLimiter(const JsonNode & limiter)
std::shared_ptr<CreatureFactionLimiter> factionLimiter = std::make_shared<CreatureFactionLimiter>();
VLC->modh->identifiers.requestIdentifier("faction", parameters[0], [=](si32 faction)
{
factionLimiter->faction = faction;
factionLimiter->faction = FactionID(faction);
});
return factionLimiter;
}
@ -1002,7 +1002,17 @@ bool JsonUtils::parseBonus(const JsonNode &ability, Bonus *b)
value = &ability["propagator"];
if (!value->isNull())
b->propagator = parseByMap(bonusPropagatorMap, value, "propagator type ");
{
//ALL_CREATURES old propagator compatibility
if(value->String() == "ALL_CREATURES")
{
logMod->warn("ALL_CREATURES propagator is deprecated. Use GLOBAL_EFFECT propagator with CREATURES_ONLY limiter");
b->addLimiter(std::make_shared<CreatureLevelLimiter>());
b->propagator = bonusPropagatorMap.at("GLOBAL_EFFECT");
}
else
b->propagator = parseByMap(bonusPropagatorMap, value, "propagator type ");
}
value = &ability["updater"];
if(!value->isNull())