Esempio n. 1
0
  public RitualoftheReturned(GameState state) {
    super(state);

    // Exile target creature card from your graveyard.
    SetGenerator deadThings =
        Intersect.instance(
            HasType.instance(Type.CREATURE), InZone.instance(GraveyardOf.instance(You.instance())));
    SetGenerator target =
        targetedBy(
            this.addTarget(
                deadThings,
                "Put a black Zombie creature token onto the battlefield. Its power is equal to that card's power and its toughness is equal to that card's toughness."));
    EventFactory exile = exile(target, "Exile target creature card from your graveyard.");
    this.addEffect(exile);

    // Put a black Zombie creature token onto the battlefield. Its power is
    // equal to that card's power and its toughness is equal to that card's
    // toughness.
    SetGenerator thatCard = NewObjectOf.instance(EffectResult.instance(exile));
    SetGenerator power = PowerOf.instance(thatCard);
    SetGenerator toughness = ToughnessOf.instance(thatCard);
    CreateTokensFactory zombie =
        new CreateTokensFactory(
            numberGenerator(1),
            power,
            toughness,
            "Put a black Zombie creature token onto the battlefield. Its power is equal to that card's power and its toughness is equal to that card's toughness.");
    zombie.setColors(Color.BLACK);
    zombie.setSubTypes(SubType.ZOMBIE);
    this.addEffect(zombie.getEventFactory());
  }
Esempio n. 2
0
  public PredatorsRapport(GameState state) {
    super(state);

    // Choose target creature you control. You gain life equal to that
    // creature's power plus its toughness.
    SetGenerator target =
        targetedBy(this.addTarget(CREATURES_YOU_CONTROL, "target creature you control"));
    this.addEffect(
        gainLife(
            You.instance(),
            Sum.instance(Union.instance(PowerOf.instance(target), ToughnessOf.instance(target))),
            "Choose target creature you control. You gain life equal to that creature's power plus its toughness."));
  }
Esempio n. 3
0
  public Vendetta(GameState state) {
    super(state);

    // Destroy target nonblack creature. It can't be regenerated.
    SetGenerator target =
        targetedBy(
            this.addTarget(
                RelativeComplement.instance(
                    CreaturePermanents.instance(), HasColor.instance(Color.BLACK)),
                "target nonblack creature"));
    this.addEffects(
        bury(this, target, "Destroy target nonblack creature. It can't be regenerated."));

    // You lose life equal to that creature's toughness.
    this.addEffect(
        loseLife(
            You.instance(),
            ToughnessOf.instance(target),
            "You lose life equal to that creature's toughness."));
  }