Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ public void prepareCompatibleData() {
// broken adventure/omen card (scryfall changed it for some reason)
// Scavenger Regent // Exude Toxin
// https://scryfall.com/card/tdm/90/scavenger-regent-exude-toxin
if (this.name.contains("//")) {
if (this.name.contains(" // ")) {
throw new IllegalArgumentException("Scryfall: unsupported data type, broken reversible_card must have same simple name"
+ this.set + " - " + this.collector_number + " - " + this.name);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -640,7 +640,7 @@ private Map<String, Integer> getlocalizedMultiverseIds(Integer englishMultiverse

private String normalizeName(String name) {
//Split card
if (name.contains("//")) {
if (name.contains(" // ")) {
if (name.indexOf('(') > 0) {
name = name.substring(0, name.indexOf('(') - 1);
}
Expand Down
68 changes: 68 additions & 0 deletions Mage.Sets/src/mage/cards/s/SPDrPilotedByPeni.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
package mage.cards.s;

import mage.MageInt;
import mage.abilities.Ability;
import mage.abilities.common.DealsDamageToAPlayerAllTriggeredAbility;
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
import mage.abilities.effects.common.counter.AddCountersTargetEffect;
import mage.abilities.keyword.VigilanceAbility;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.SetTargetPointer;
import mage.constants.SubType;
import mage.constants.SuperType;
import mage.counters.CounterType;
import mage.filter.FilterPermanent;
import mage.filter.common.FilterControlledCreaturePermanent;
import mage.filter.predicate.permanent.ModifiedPredicate;
import mage.target.common.TargetCreaturePermanent;

import java.util.UUID;

/**
* @author TheElk801
*/
public final class SPDrPilotedByPeni extends CardImpl {

private static final FilterPermanent filter = new FilterControlledCreaturePermanent("a modified creature you control");

static {
filter.add(ModifiedPredicate.instance);
}

public SPDrPilotedByPeni(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{3}{W}{U}");

this.supertype.add(SuperType.LEGENDARY);
this.subtype.add(SubType.SPIDER);
this.subtype.add(SubType.HERO);

this.power = new MageInt(4);
this.toughness = new MageInt(4);

// Vigilance
this.addAbility(VigilanceAbility.getInstance());

// When SP//dr enters, put a +1/+1 counter on target creature.
Ability ability = new EntersBattlefieldTriggeredAbility(new AddCountersTargetEffect(CounterType.P1P1.createInstance()));
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);

// Whenever a modified creature you control deals combat damage to a player, draw a card.
this.addAbility(new DealsDamageToAPlayerAllTriggeredAbility(
new DrawCardSourceControllerEffect(1), filter,
false, SetTargetPointer.NONE, true
));
}

private SPDrPilotedByPeni(final SPDrPilotedByPeni card) {
super(card);
}

@Override
public SPDrPilotedByPeni copy() {
return new SPDrPilotedByPeni(this);
}
}
2 changes: 2 additions & 0 deletions Mage.Sets/src/mage/sets/MarvelsSpiderMan.java
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,8 @@ private MarvelsSpiderMan() {
cards.add(new SetCardInfo("Rocket-Powered Goblin Glider", 172, Rarity.RARE, mage.cards.r.RocketPoweredGoblinGlider.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Rocket-Powered Goblin Glider", 281, Rarity.RARE, mage.cards.r.RocketPoweredGoblinGlider.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Romantic Rendezvous", 86, Rarity.COMMON, mage.cards.r.RomanticRendezvous.class));
cards.add(new SetCardInfo("SP//dr, Piloted by Peni", 147, Rarity.UNCOMMON, mage.cards.s.SPDrPilotedByPeni.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("SP//dr, Piloted by Peni", 199, Rarity.UNCOMMON, mage.cards.s.SPDrPilotedByPeni.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Sandman's Quicksand", 63, Rarity.UNCOMMON, mage.cards.s.SandmansQuicksand.class));
cards.add(new SetCardInfo("Sandman, Shifting Scoundrel", 112, Rarity.RARE, mage.cards.s.SandmanShiftingScoundrel.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Sandman, Shifting Scoundrel", 266, Rarity.RARE, mage.cards.s.SandmanShiftingScoundrel.class, NON_FULL_USE_VARIOUS));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1471,7 +1471,7 @@ public void assertHandCount(Player player, String cardName, int count) throws As
cardName = EmptyNames.replaceTestCommandByObjectName(cardName);

int actual;
if (cardName.contains("//")) { // special logic for checked split cards, because in game logic of card name filtering is different from in test
if (cardName.contains(" // ")) { // special logic for checked split cards, because in game logic of card name filtering is different from in test
actual = 0;
for (Card card : currentGame.getPlayer(player.getId()).getHand().getCards(currentGame)) {
if (CardUtil.haveSameNames(card.getName(), cardName, true)) {
Expand Down