@Override public RepairAbility copy() { return new RepairAbility(this); } }
@Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { Set<Card> cards = controller.getGraveyard().getCards(filterCard, game); cards.stream().forEach((card) -> { game.getState().addOtherAbility(card, new RepairAbility(6)); }); return true; } return false; } }
public SuperBattleDroid(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT,CardType.CREATURE},"{5}{U}"); this.subtype.add(SubType.DROID); this.power = new MageInt(4); this.toughness = new MageInt(5); // Repair 2 this.addAbility(new RepairAbility(2)); }
public MaintenanceHangar(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{2}{W}"); // At the beginning of your upkeep, remove an additional repair counter from each card in your graveyard. this.addAbility(new BeginningOfUpkeepTriggeredAbility(new RemoveCounterMaintenanceHangarEffect(), TargetController.YOU, false)); // Starship creatures you control and starship creatures in your graveyard have Repair 6. Effect effect = new GainAbilityControlledEffect(new RepairAbility(6), Duration.WhileOnBattlefield, filterPermanent); effect.setText("Starship creatures you control"); Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, effect); ability.addEffect(new MaintenanceHangarEffect()); this.addAbility(ability); }
public DarkTrooper(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{3}"); this.subtype.add(SubType.DROID); this.subtype.add(SubType.TROOPER); this.power = new MageInt(2); this.toughness = new MageInt(2); // Repair 2 this.addAbility(new RepairAbility(2)); }
public TriFighter(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{1}{U/B}{U/B}"); this.subtype.add(SubType.DROID); this.subtype.add(SubType.STARSHIP); this.power = new MageInt(2); this.toughness = new MageInt(2); // Spaceflight this.addAbility(SpaceflightAbility.getInstance()); // Repair 3 this.addAbility(new RepairAbility(3)); }
public MouseDroid(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{1}{U}"); this.subtype.add(SubType.DROID); this.power = new MageInt(0); this.toughness = new MageInt(1); // When Mouse Droid dies, draw a card. this.addAbility(new DiesTriggeredAbility(new DrawCardSourceControllerEffect(1))); // Repair 3 this.addAbility(new RepairAbility(3)); }
public SecurityDroid(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT,CardType.CREATURE},"{1}{W}"); this.subtype.add(SubType.DROID); this.power = new MageInt(1); this.toughness = new MageInt(1); // When Security Droid enters the battlefield, create a 1/1 colorless Droid creature token. this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new DroidToken(), 1), false)); // Repair 3 this.addAbility(new RepairAbility(3)); }
public MaintenanceDroid(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{W}{U}"); this.subtype.add(SubType.DROID); this.power = new MageInt(1); this.toughness = new MageInt(2); // {T}: Choose target card you own with a repair counter on it. You may remove a repair counter from it or put another repair counter on it. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new MaintenanceDroidEffect(), new TapSourceCost()); ability.addTarget(new TargetCardInYourGraveyard(filter)); this.addAbility(ability); // Repair 4 this.addAbility(new RepairAbility(4)); }
public ArmedProtocolDroid(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{1}{U}"); this.subtype.add(SubType.DROID); this.subtype.add(SubType.ROGUE); this.power = new MageInt(1); this.toughness = new MageInt(3); // When {this} enters the battlefield, target nonartifact creature gets -2/-0 until end of turn. Ability ability = new EntersBattlefieldTriggeredAbility(new BoostTargetEffect(-2, 0, Duration.EndOfTurn), false); ability.addTarget(new TargetCreaturePermanent(filter)); this.addAbility(ability); // Repair 3 this.addAbility(new RepairAbility(3)); }
public ProbeDroid(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT,CardType.CREATURE},"{1}{U}"); this.subtype.add(SubType.DROID); this.subtype.add(SubType.SCOUT); this.power = new MageInt(1); this.toughness = new MageInt(1); // When Probe Droid enters the battlefield, target player reveals their hand. Ability ability = new EntersBattlefieldTriggeredAbility(new LookAtTargetPlayerHandEffect()); ability.addTarget(new TargetPlayer()); this.addAbility(ability); // Repair 3 this.addAbility(new RepairAbility(3)); }
public Droideka(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT,CardType.CREATURE},"{4}{W}"); this.subtype.add(SubType.DROID); this.power = new MageInt(3); this.toughness = new MageInt(6); // {2}{U}: Change a target of target spell or ability to Droideka. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ChangeATargetOfTargetSpellAbilityToSourceEffect(), new ManaCostsImpl("{2}{U}")); ability.addTarget(new TargetStackObject()); this.addAbility(ability); // Repair 3 this.addAbility(new RepairAbility(3)); }
public DroidCommando(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{2}{B}"); this.subtype.add(SubType.DROID); this.power = new MageInt(2); this.toughness = new MageInt(2); // When Droid Commando dies, target player loses 2 life and you gain 2 life. Ability ability = new DiesTriggeredAbility(new LoseLifeTargetEffect(2)); ability.addEffect(new GainLifeEffect(2)); ability.addTarget(new TargetPlayer()); this.addAbility(ability); // Repair 3 this.addAbility(new RepairAbility(3)); }
public C3POAndR2D2(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT,CardType.CREATURE},"{2}{W}{U}"); addSuperType(SuperType.LEGENDARY); this.subtype.add(SubType.DROID); this.power = new MageInt(2); this.toughness = new MageInt(2); // When C-3PO and R2D2 leaves the battlefield, you gain 4 life and draw a card. Ability ability = new LeavesBattlefieldTriggeredAbility(new GainLifeEffect(4), false); Effect effect = new DrawCardSourceControllerEffect(1); effect.setText("and draw a card"); ability.addEffect(effect); this.addAbility(ability); // Repair 2 this.addAbility(new RepairAbility(2)); }
public IG88B(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{1}{B}{B}"); addSuperType(SuperType.LEGENDARY); this.subtype.add(SubType.DROID); this.subtype.add(SubType.HUNTER); this.power = new MageInt(1); this.toughness = new MageInt(4); // Deathtouch this.addAbility(DeathtouchAbility.getInstance()); // <i>Bounty</i> — Whenever IF-88B deals combat damage to a player, that player loses life equal to the number of bounty counters on creatures he or she controls. this.addAbility(new DealsCombatDamageToAPlayerTriggeredAbility( new LoseLifeTargetEffect(new CountersOnDefendingPlayerCreaturesCount(CounterType.BOUNTY)), false, "<i>Bounty</i> — Whenever {this} deals combat damage to a player, that player loses life equal to the number of bounty counters on creatures he or she controls", true) ); // Repair 3 this.addAbility(new RepairAbility(3)); }
public TankDroid(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{4}{W}{U}{B}"); this.subtype.add(SubType.DROID); this.power = new MageInt(5); this.toughness = new MageInt(5); // Whenever Tank Droid enters the battlefield, attacks, blocks or dies, create a 1/1 colorless Droid token creature. Ability ability = new AttacksOrBlocksTriggeredAbility(new CreateTokenEffect(new DroidToken()), false); this.addAbility(ability); ability = new EntersBattlefieldOrDiesSourceTriggeredAbility(new CreateTokenEffect(new DroidToken()), false); this.addAbility(ability); // Repair 3 this.addAbility(new RepairAbility(3)); }
public AstromechDroid(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{W}"); this.subtype.add(SubType.DROID); this.power = new MageInt(0); this.toughness = new MageInt(1); // {T}: Target starship creature you control gets +1/+1 and gains vigilance until end of turn. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 1, Duration.EndOfTurn) .setText("Target starship creature you control gets +1/+1"), new TapSourceCost()); ability.addEffect(new GainAbilityTargetEffect(VigilanceAbility.getInstance(), Duration.EndOfTurn) .setText("and gains vigilance until end of turn")); ability.addTarget(new TargetCreaturePermanent(filter)); this.addAbility(ability); // Repair 4 this.addAbility(new RepairAbility(4)); }
public AAT1(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{1}{W}{U}{B}"); this.subtype.add(SubType.DROID); this.subtype.add(SubType.CONSTRUCT); this.power = new MageInt(4); this.toughness = new MageInt(4); // Whenever a repair counter is removed from a creature card your graveyard, you may pay {W/B}. If you do, target player loses 1 life and you gain 1 life. DoIfCostPaid effect = new DoIfCostPaid(new LoseLifeTargetEffect(1), new ManaCostsImpl("{W/B}")); Effect additionalEffect = new GainLifeEffect(1); additionalEffect.setText("and you gain 1 life"); effect.addEffect(additionalEffect); Ability ability = new AAT1TriggeredAbility(effect); ability.addTarget(new TargetPlayer()); this.addAbility(ability); // Repair 4 this.addAbility(new RepairAbility(4)); }