예제 #1
0
  public MidnightHaunting(GameState state) {
    super(state);

    // Put two 1/1 white Spirit creature tokens with flying onto the
    // battlefield.
    CreateTokensFactory factory =
        new CreateTokensFactory(
            2, 1, 1, "Put two 1/1 white Spirit creature tokens with flying onto the battlefield.");
    factory.setColors(Color.WHITE);
    factory.setSubTypes(SubType.SPIRIT);
    factory.addAbility(org.rnd.jmagic.abilities.keywords.Flying.class);
    this.addEffect(factory.getEventFactory());
  }
예제 #2
0
    public RocEggAbility1(GameState state) {
      super(
          state,
          "When Roc Egg dies, put a 3/3 white Bird creature token with flying onto the battlefield.");
      this.addPattern(whenThisDies());

      CreateTokensFactory token =
          new CreateTokensFactory(
              1, 3, 3, "Put a 3/3 white Bird creature token with flying onto the battlefield.");
      token.setColors(Color.WHITE);
      token.setSubTypes(SubType.BIRD);
      token.addAbility(Flying.class);
      this.addEffect(token.getEventFactory());
    }
예제 #3
0
    public KnightlyValorAbility1(GameState state) {
      super(
          state,
          "When Knightly Valor enters the battlefield, put a 2/2 white Knight creature token with vigilance onto the battlefield.");
      this.addPattern(whenThisEntersTheBattlefield());

      CreateTokensFactory factory =
          new CreateTokensFactory(
              1,
              2,
              2,
              "Put a 2/2 white Knight creature token with vigilance onto the battlefield.");
      factory.setColors(Color.WHITE);
      factory.setSubTypes(SubType.KNIGHT);
      factory.addAbility(Vigilance.class);
      this.addEffect(factory.getEventFactory());
    }
예제 #4
0
  public CribSwap(GameState state) {
    super(state);

    // Changeling (This card is every creature type at all times.)
    this.addAbility(new org.rnd.jmagic.abilities.keywords.Changeling(state));

    // Exile target creature.
    SetGenerator target =
        targetedBy(this.addTarget(CreaturePermanents.instance(), "target creature"));
    this.addEffect(exile(target, "Exile target creature."));

    // Its controller puts a 1/1 colorless Shapeshifter creature token with
    // changeling onto the battlefield.
    CreateTokensFactory token =
        new CreateTokensFactory(
            1,
            1,
            1,
            "Its controller puts a 1/1 colorless Shapeshifter creature token with changeling onto the battlefield.");
    token.setController(ControllerOf.instance(target));
    token.setSubTypes(SubType.SHAPESHIFTER);
    token.addAbility(org.rnd.jmagic.abilities.keywords.Changeling.class);
    this.addEffect(token.getEventFactory());
  }