Fixed primitives, updated italian lang file, added a new setting to sort decks by creation date (by default they will be sorted by name), added new filters to match cards that don't contain a particular color or that are multicolored, fixed an issue when the transformation with uynt is triggered by instant/sorcery or by card that left the battlefield before the ability ending turn, fixed a rendering overlap on mana symbols in deck editor, fixed some crashes on ManaCost parser (e.g. Filter by mana producer).

This commit is contained in:
Vittorio Alfieri
2021-11-15 21:38:04 +01:00
parent 2eed51dea6
commit 477ffa6a0c
16 changed files with 204 additions and 60 deletions
+5 -2
View File
@@ -94,10 +94,13 @@ vector<DeckMetaData *> GameState::BuildDeckList(const string& path, const string
}
meta = NULL;
}
// Now decks can be sorted by name or by creation date.
if(!options[Options::SORTINGDECKS].number)
std::sort(retList.begin(), retList.end(), sortByName); // Ordered by name from A to Z.
else
std::reverse(retList.begin(), retList.end()); // Ordered by creation date from the last to the first one (e.g. we consider deck2.txt newer than deck1.txt).
std::sort(retList.begin(), retList.end(), sortByName);
return retList;
}
// build a menu with the given deck list and return a vector of the deck ids created.