Package mage.abilities.costs.common

Examples of mage.abilities.costs.common.ReturnToHandTargetCost.canPay()


    @Override
    public boolean replaceEvent(GameEvent event, Ability source, Game game) {
        Player player = game.getPlayer(event.getPlayerId());
        if ( player != null ) {
            ReturnToHandTargetCost attackCost = new ReturnToHandTargetCost(new TargetControlledPermanent(filter));
            if ( attackCost.canPay(source, source.getSourceId(), event.getPlayerId(), game) &&
                 player.chooseUse(Outcome.Neutral, "Return an enchantment you control to hand to attack?", game) )
            {
                if (attackCost.pay(source, game, source.getSourceId(), event.getPlayerId(), true) ) {
                    return false;
                }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.