Fixed test

This commit is contained in:
Oleg Agafonov 2020-07-11 21:01:40 +04:00
parent 81e5650972
commit 219ab89bcc
8 changed files with 40 additions and 26 deletions

View file

@ -46,13 +46,13 @@ public abstract class TriggeredManaAbility extends TriggeredAbilityImpl implemen
@Override
public List<Mana> getNetMana(Game game) {
if (game != null) {
List<Mana> newNetMana = new ArrayList<>();
List<Mana> netMana = new ArrayList<>();
for (Effect effect : getEffects()) {
if (effect instanceof ManaEffect) {
newNetMana.addAll(((ManaEffect) effect).getNetMana(game, this));
netMana.addAll(((ManaEffect) effect).getNetMana(game, this));
}
}
return newNetMana;
return netMana;
}
return new ArrayList<>(netMana);
}