* Performance: memory usage optimization for deck editor (part 2 of removed bloated usage of ManaCosts -> ManaColor objects, see #7515);

This commit is contained in:
Oleg Agafonov 2021-02-12 22:12:18 +04:00
parent c1dea5b21e
commit 10e557b873
25 changed files with 164 additions and 113 deletions

View file

@ -2316,7 +2316,7 @@ public class ComputerPlayer extends PlayerImpl implements Player {
if (differentColorsInCost > 0 && differentColorsInCost < 3) {
// if some colors were already chosen, total amount shouldn't be more than 3
if (chosenSymbols.size() + differentColorsInCost < 4) {
for (String symbol : picked.card.getManaCost().getSymbols()) {
for (String symbol : picked.card.getManaCostSymbols()) {
symbol = symbol.replace("{", "").replace("}", "");
if (RateCard.isColoredMana(symbol)) {
chosenSymbols.add(symbol);