mirror of
https://github.com/vcmi/vcmi.git
synced 2024-11-24 08:32:34 +02:00
Merge pull request #1006 from AgostonSzepessy/dev/agos/small-fixes
Small misc fixes
This commit is contained in:
commit
557512b308
@ -9,7 +9,7 @@ VCMI is work-in-progress attempt to recreate engine for Heroes III, giving it ne
|
||||
* Homepage: https://vcmi.eu/
|
||||
* Wiki: https://wiki.vcmi.eu/
|
||||
* Forums: https://forum.vcmi.eu/
|
||||
* Bugtracker: https://bugs.vcmi.eu/
|
||||
* Bugtracker: https://github.com/vcmi/vcmi/issues
|
||||
* Slack: https://slack.vcmi.eu/
|
||||
|
||||
## Installation guides
|
||||
|
@ -825,11 +825,10 @@ CStackBasicDescriptor CGHeroInstance::calculateNecromancy (const BattleResult &b
|
||||
}
|
||||
else
|
||||
{
|
||||
auto quality = [getCreatureID](std::shared_ptr<Bonus> pick) -> std::vector<int>
|
||||
auto quality = [getCreatureID](std::shared_ptr<Bonus> pick) -> std::tuple<int, int, int>
|
||||
{
|
||||
const CCreature * c = VLC->creh->objects[getCreatureID(pick)];
|
||||
std::vector<int> v = {c->level, static_cast<int>(c->cost.marketValue()), -pick->additionalInfo[1]};
|
||||
return v;
|
||||
return std::tuple<int, int, int> {c->level, static_cast<int>(c->cost.marketValue()), -pick->additionalInfo[1]};
|
||||
};
|
||||
if(quality(topPick) < quality(newPick))
|
||||
topPick = newPick;
|
||||
|
Loading…
Reference in New Issue
Block a user