Package mage

Examples of mage.Mana


        this.color.setBlack(true);

        // Add {B}{B}{B} to your mana pool.
        // Threshold — Add {B}{B}{B}{B}{B} to your mana pool instead if seven or more cards are in your graveyard.
        this.getSpellAbility().addEffect(new ConditionalManaEffect(
                new BasicManaEffect(new Mana(0, 0, 0, 0, 5, 0, 0)),
                new BasicManaEffect(new Mana(0, 0, 0, 0, 3, 0, 0)),
                new CardsInControllerGraveCondition(7),
                "Add {B}{B}{B} to your mana pool.<br/><br/><i>Threshold<i/> - Add {B}{B}{B}{B}{B} to your mana pool instead if seven or more cards are in your graveyard"));
    }
View Full Code Here


        this.expansionSetCode = "ODY";

        // {tap}: Add {1} to your mana pool.
        this.addAbility(new ColorlessManaAbility());
        // {5}, {tap}: Add {W}{U}{B}{R}{G} to your mana pool.
        Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(1, 1, 1, 1, 1, 0, 0), new ManaCostsImpl("{5}"));
        ability.addCost(new TapSourceCost());
        this.addAbility(ability);
    }
View Full Code Here

        int white = 0;
        Set<Card> cards = deck.getCards();
        int land_number = DEFAULT_SEALED_DECK_CARD_NUMBER - cards.size();
        if(land_number < 0) land_number = 0;
        for (Card cd : cards) {
            Mana m = cd.getManaCost().getMana();
            red += m.getRed();
            green += m.getGreen();
            black += m.getBlack();
            blue += m.getBlue();
            white += m.getWhite();
        }
        int total = red + green + black + blue + white;
        int redcards = Math.round(land_number*((float)red/(float)total));
        total -= red;   land_number -= redcards;
        int greencards = Math.round(land_number*((float)green/(float)total));
 
View Full Code Here

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

        // {1}, Sacrifice Treva's Attendant: Add {G}{W}{U} to your mana pool.
        Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 1, 1, 1, 0, 0, 0), new ManaCostsImpl("{1}"));
        ability.addCost(new SacrificeSourceCost());
        this.addAbility(ability);
    }
View Full Code Here

        // Sulfur Vent enters the battlefield tapped.
        this.addAbility(new EntersBattlefieldTappedAbility());
        // {tap}: Add {B} to your mana pool.
        this.addAbility(new BlackManaAbility());
        // {tap}, Sacrifice Sulfur Vent: Add {U}{R} to your mana pool.
        Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(1, 0, 1, 0, 0, 0, 0), new TapSourceCost());
        ability.addCost(new SacrificeSourceCost());
        this.addAbility(ability);
    }
View Full Code Here

        // Geothermal Crevice enters the battlefield tapped.
        this.addAbility(new EntersBattlefieldTappedAbility());
        // {tap}: Add {R} to your mana pool.
        this.addAbility(new RedManaAbility());
        // {tap}, Sacrifice Geothermal Crevice: Add {B}{G} to your mana pool.
        Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(new Mana(0, 1, 0, 0, 1, 0, 0)), new TapSourceCost());
        ability.addCost(new SacrificeSourceCost());
        this.addAbility(ability);
    }
View Full Code Here

    public DarkRitual(UUID ownerId) {
        super(ownerId, 24, "Dark Ritual", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{B}");
        this.expansionSetCode = "HOP";
        this.color.setBlack(true);
        this.getSpellAbility().addEffect(new BasicManaEffect(new Mana(0, 0, 0, 0, 3, 0, 0)));
    }
View Full Code Here

       
        this.addAbility(new EntersBattlefieldTappedAbility());
       
        this.addAbility(new EntersBattlefieldTriggeredAbility(new ReturnToHandChosenControlledPermanentEffect(filter), false));
       
        this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(1, 1, 0, 0, 0, 0, 0), new TapSourceCost()));
    }
View Full Code Here

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

        // {1}, Sacrifice Crosis's Attendant: Add {U}{B}{R} to your mana pool.
        Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(1, 0, 1, 0, 1, 0, 0), new ManaCostsImpl("{1}"));
        ability.addCost(new SacrificeSourceCost());
        this.addAbility(ability);
    }
View Full Code Here

    public boolean apply(Game game, Ability source) {
        Player controller = game.getPlayer(source.getControllerId());
        if(controller != null){
                int x = 2;

            Mana mana = new Mana();
            for(int i = 0; i < x; i++){
                ChoiceColor choiceColor = new ChoiceColor();
                while (controller.isInGame() && !controller.choose(Outcome.Benefit, choiceColor, game)) {
                }

                if (choiceColor.getColor().isBlack()) {
                    mana.addBlack();
                } else if (choiceColor.getColor().isBlue()) {
                    mana.addBlue();
                } else if (choiceColor.getColor().isRed()) {
                    mana.addRed();
                } else if (choiceColor.getColor().isGreen()) {
                    mana.addGreen();
                } else if (choiceColor.getColor().isWhite()) {
                    mana.addWhite();
                }
            }

            controller.getManaPool().addMana(mana, game, source);
            return true;
View Full Code Here

TOP

Related Classes of mage.Mana

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.