* Fixed some problems with abilities that let permanents become artifact creatures but only added creature card type instead of artifact and creature card type (fixes #4290).

This commit is contained in:
LevelX2 2017-12-31 11:31:58 +01:00
parent 6a23a0f707
commit 519eae42fc
24 changed files with 225 additions and 177 deletions

View file

@ -35,7 +35,6 @@ import mage.abilities.costs.common.DiscardCardCost;
import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.costs.mana.ManaCostsImpl;
import mage.abilities.effects.ContinuousEffectImpl;
import mage.constants.SubType;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
@ -43,6 +42,7 @@ import mage.constants.Duration;
import mage.constants.Layer;
import mage.constants.Outcome;
import mage.constants.SubLayer;
import mage.constants.SubType;
import mage.constants.Zone;
import mage.filter.common.FilterArtifactPermanent;
import mage.filter.predicate.Predicates;
@ -113,6 +113,9 @@ class ToymakerEffect extends ContinuousEffectImpl {
switch (layer) {
case TypeChangingEffects_4:
if (sublayer == SubLayer.NA) {
if (!artifact.isArtifact()) {
artifact.addCardType(CardType.ARTIFACT);
}
if (!artifact.isCreature()) {
artifact.addCardType(CardType.CREATURE);
}