Package mage.abilities.effects.common.continious

Examples of mage.abilities.effects.common.continious.GainAbilityAllEffect


        this.color.setBlue(true);

        // All creatures have "At the beginning of your upkeep, sacrifice this creature unless you pay {1}."
        Ability gainedAbility = new BeginningOfUpkeepTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new GenericManaCost(1)), TargetController.YOU, false);
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(gainedAbility, Duration.WhileOnBattlefield, new FilterCreaturePermanent("creatures"),
                "All creatures have \"At the beginning of your upkeep, sacrifice this creature unless you pay {1}")));
    }
View Full Code Here


        this.expansionSetCode = "DST";
        this.supertype.add("Legendary");
        this.subtype.add("Equipment");

        // Equipment named Sword of Kaldra, Shield of Kaldra, and Helm of Kaldra are indestructible.
        Effect effect = new GainAbilityAllEffect(IndestructibleAbility.getInstance(), Duration.WhileOnBattlefield, filter, false);
        effect.setText("Equipment named Sword of Kaldra, Shield of Kaldra, and Helm of Kaldra are indestructible");
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect));
        // Equipped creature is indestructible.
        effect = new GainAbilityAttachedEffect(IndestructibleAbility.getInstance(), AttachmentType.EQUIPMENT, Duration.WhileOnBattlefield);
        effect.setText("Equipped creature is indestructible");
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect));
        // Equip {4}
        this.addAbility(new EquipAbility(Outcome.Benefit, new GenericManaCost(4)));
    }
View Full Code Here

        // Other Merfolk creatures get +1/+1 and have islandwalk.
        Effect effect = new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, filter, true);
        effect.setText("Other Merfolk creatures get +1/+1");
        Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, effect);
        effect = new GainAbilityAllEffect(new IslandwalkAbility(), Duration.WhileOnBattlefield, filter, true);
        effect.setText("and have islandwalk");
        ability.addEffect(effect);
        this.addAbility(ability);
    }
View Full Code Here

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

        // Other Elf creatures get +1/+1 and have forestwalk. (They're unblockable as long as defending player controls a Forest.)
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, filter, true)));
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(new ForestwalkAbility(), Duration.WhileOnBattlefield, filter, true)));
    }
View Full Code Here

        this.color.setRed(true);
        this.power = new MageInt(2);
        this.toughness = new MageInt(2);
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, filter, true)));
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(new MountainwalkAbility(), Duration.WhileOnBattlefield, filter, true)));
    }
View Full Code Here

        this.toughness = new MageInt(3);

        // Outlast 1G
        this.addAbility(new OutlastAbility(new ManaCostsImpl("{1}{G}")));
        // Each creature you control with a +1/+1 counter on it has reach.
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(ReachAbility.getInstance(), Duration.WhileOnBattlefield, filter,
                "Each creature you control with a +1/+1 counter on it has reach")));

    }
View Full Code Here

        this.color.setBlack(true);

        // As Cover of Darkness enters the battlefield, choose a creature type.
        this.addAbility(new AsEntersBattlefieldAbility(new ChooseCreatureTypeEffect(Outcome.AddAbility)));
        // Creatures of the chosen type have fear.
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(FearAbility.getInstance(), Duration.WhileOnBattlefield, new FilterCoverOfDarkness())));
    }
View Full Code Here

        this.expansionSetCode = "ONS";

        this.color.setBlack(true);

        // All creatures gain fear until end of turn.
        this.getSpellAbility().addEffect(new GainAbilityAllEffect(FearAbility.getInstance(), Duration.EndOfTurn, new FilterCreaturePermanent("All creatures")));
        // Cycling {1}{B}
        this.addAbility(new CyclingAbility(new ManaCostsImpl("{1}{B}")));
        // When you cycle Dirge of Dread, you may have target creature gain fear until end of turn.
        Ability ability = new CycleTriggeredAbility(new GainAbilityTargetEffect(FearAbility.getInstance(), Duration.EndOfTurn), true);
        ability.addTarget(new TargetCreaturePermanent());
View Full Code Here

        this.toughness = new MageInt(3);

        // Outlast G
        this.addAbility(new OutlastAbility(new ManaCostsImpl("{G}")));
        // Each creature you control with a +1/+1 counter on it has trample.
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(TrampleAbility.getInstance(), Duration.WhileOnBattlefield, filter, rule)));


    }
View Full Code Here

        this.color.setBlack(true);
        this.power = new MageInt(2);
        this.toughness = new MageInt(3);

        // Other Zombie creatures have swampwalk.
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(new SwampwalkAbility(), Duration.WhileOnBattlefield, filter, true)));
        // Other Zombies have "{B}: Regenerate this permanent."
        Effect effect = new GainAbilityAllEffect(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl("{B}")), Duration.WhileOnBattlefield, filter, true);
        effect.setText("Other Zombies have \"{B}: Regenerate this permanent.\"");
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect));

    }
View Full Code Here

TOP

Related Classes of mage.abilities.effects.common.continious.GainAbilityAllEffect

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.