mirror of
https://github.com/correl/mage.git
synced 2024-12-25 11:11:16 +00:00
[ZNR] fixed Crawling Barrens giving multiple instances of added subtypes and card types (#7046)
This commit is contained in:
parent
c233ca57d8
commit
40e663e2cf
1 changed files with 9 additions and 1 deletions
|
@ -90,6 +90,9 @@ public class BecomesCreatureSourceEffect extends ContinuousEffectImpl implements
|
||||||
permanent.getCardType().clear();
|
permanent.getCardType().clear();
|
||||||
}
|
}
|
||||||
for (CardType cardType : token.getCardType()) {
|
for (CardType cardType : token.getCardType()) {
|
||||||
|
if (permanent.getCardType().contains(cardType)) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
permanent.addCardType(cardType);
|
permanent.addCardType(cardType);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -97,7 +100,12 @@ public class BecomesCreatureSourceEffect extends ContinuousEffectImpl implements
|
||||||
permanent.getSubtype(game).retainAll(SubType.getLandTypes());
|
permanent.getSubtype(game).retainAll(SubType.getLandTypes());
|
||||||
}
|
}
|
||||||
if (!token.getSubtype(game).isEmpty()) {
|
if (!token.getSubtype(game).isEmpty()) {
|
||||||
permanent.getSubtype(game).addAll(token.getSubtype(game));
|
for (SubType subType : token.getSubtype(game)) {
|
||||||
|
if (permanent.hasSubtype(subType, game)) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
permanent.getSubtype(game).add(subType);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
permanent.setIsAllCreatureTypes(token.isAllCreatureTypes());
|
permanent.setIsAllCreatureTypes(token.isAllCreatureTypes());
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue