mirror of
https://github.com/vcmi/vcmi.git
synced 2024-12-14 10:12:59 +02:00
sorted
This commit is contained in:
parent
74b4fbfceb
commit
988d36bd13
@ -29,7 +29,7 @@
|
||||
"vcmi.adventureMap.replayOpponentTurnNotImplemented" : "Sorry, replay opponent turn is not implemented yet!",
|
||||
|
||||
"vcmi.bonusSource.artifact" : "Artifact",
|
||||
"vcmi.bonusSource.creature" : "Creature",
|
||||
"vcmi.bonusSource.creature" : "Ability",
|
||||
"vcmi.bonusSource.spell" : "Spell",
|
||||
"vcmi.bonusSource.hero" : "Hero",
|
||||
"vcmi.bonusSource.commander" : "Commander",
|
||||
|
@ -829,6 +829,9 @@ void CStackWindow::initBonusesList()
|
||||
BonusList output;
|
||||
BonusList input;
|
||||
input = *(info->stackNode->getBonuses(CSelector(Bonus::Permanent), Selector::all));
|
||||
std::sort(input.begin(), input.end(), [this](std::shared_ptr<Bonus> v1, std::shared_ptr<Bonus> & v2){
|
||||
return v1->source == v2->source ? info->stackNode->bonusToString(v1, false) < info->stackNode->bonusToString(v2, false) : v1->source == BonusSource::CREATURE_ABILITY || (v1->source < v2->source);
|
||||
});
|
||||
|
||||
while(!input.empty())
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user