Examples of TappedPredicate


Examples of mage.filter.predicate.permanent.TappedPredicate

    public FilterCreatureForAttack(String name) {
        super(name);
        this.add(Predicates.not(new AttackingPredicate()));
        this.add(Predicates.not(new BlockingPredicate()));
        this.add(Predicates.not(new TappedPredicate()));
        this.add(Predicates.not(new AbilityPredicate(DefenderAbility.class)));
        this.add(new CanTapPredicate());
    }
View Full Code Here

Examples of mage.filter.predicate.permanent.TappedPredicate

        this("untapped creature");
    }

    public FilterUntappedCreature(String name) {
        super(name);
        this.add(Predicates.not(new TappedPredicate()));
    }
View Full Code Here

Examples of mage.filter.predicate.permanent.TappedPredicate

        this("");
    }

    public FilterCreatureForCombat(String name) {
        super(name);
        this.add(Predicates.not(new TappedPredicate()));
    }
View Full Code Here

Examples of mage.filter.predicate.permanent.TappedPredicate

    @Override
    public boolean apply(Game game, Ability source) {
        Player opponent = game.getPlayer(this.getTargetPointer().getFirst(game, source));
            if (opponent != null) {
            FilterCreaturePermanent filter = new FilterCreaturePermanent();
            filter.add(new TappedPredicate());
            filter.add(new ControllerIdPredicate(opponent.getId()));
            return new DrawCardSourceControllerEffect(game.getBattlefield().count(filter, source.getSourceId(), source.getControllerId(), game)).apply(game, source);
        }
        return false;
    }
View Full Code Here

Examples of mage.filter.predicate.permanent.TappedPredicate

            FilterPermanent filter = new FilterPermanent();
            filter.add(new CardTypePredicate(type));
           
           
            if(choiceImpl.getChoice().equals("Untap")){
                filter.add(new TappedPredicate());
                for (Permanent permanent : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game)) {
                    if(permanent.getControllerId().equals(target)){
                        permanent.untap(game);
                    }
                }
            }
            else{
                filter.add(Predicates.not(new TappedPredicate()));
                for (Permanent permanent : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game)) {
                    if(permanent.getControllerId().equals(target)){
                        permanent.tap(game);
                    }
                }
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.