congrats Icon
New! Announcing our next generation AI code completions
Read here
Tabnine Logo
SpellCastAllTriggeredAbility.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
mage.abilities.common.SpellCastAllTriggeredAbility
constructor

Best Java code snippets using mage.abilities.common.SpellCastAllTriggeredAbility.<init> (Showing top 20 results out of 315)

origin: magefree/mage

public ManaBreach(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{2}{U}");
  // Whenever a player casts a spell, that player returns a land he or she controls to its owner's hand.
  this.addAbility(new SpellCastAllTriggeredAbility(new ManaBreachEffect(), StaticFilters.FILTER_SPELL, false, SetTargetPointer.PLAYER));
}
origin: magefree/mage

public AngelsFeather(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{2}");
  // Whenever a player casts a white spell, you may gain 1 life.
  this.addAbility(new SpellCastAllTriggeredAbility(new GainLifeEffect(1), filter, true));
}
origin: magefree/mage

public AetherBarrier(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}");
  // Whenever a player casts a creature spell, that player sacrifices a permanent unless he or she pays {1}.
  this.addAbility(new SpellCastAllTriggeredAbility(Zone.BATTLEFIELD, new AetherBarrierEffect(),
      StaticFilters.FILTER_SPELL_A_CREATURE, false, SetTargetPointer.PLAYER));
}
origin: magefree/mage

public IceCave(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{3}{U}{U}");
  // Whenever a player casts a spell, any other player may pay that spell's mana cost. If a player does, counter the spell. (Mana cost includes color.)
  this.addAbility(new SpellCastAllTriggeredAbility(Zone.BATTLEFIELD, new IceCaveEffect(), StaticFilters.FILTER_SPELL_A, false, SetTargetPointer.SPELL));
}
origin: magefree/mage

public InTheEyeOfChaos(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{2}{U}");
  addSuperType(SuperType.WORLD);
  // Whenever a player casts an instant spell, counter it unless that player pays {X}, where X is its converted mana cost.
  this.addAbility(new SpellCastAllTriggeredAbility(Zone.BATTLEFIELD, new InTheEyeOfChaosEffect(), filter, false, SetTargetPointer.SPELL));
}
origin: magefree/mage

public Tangleroot(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{3}");
  // Whenever a player casts a creature spell, that player adds {G}.
  this.addAbility(new SpellCastAllTriggeredAbility(
      new AddManaToManaPoolTargetControllerEffect(Mana.GreenMana(1), "their"), StaticFilters.FILTER_SPELL_A_CREATURE, false, SetTargetPointer.PLAYER));
}
origin: magefree/mage

public UnifyingTheory(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{1}{U}");
  // Whenever a player casts a spell, that player may pay {2}. If the player does, he or she draws a card.
  this.addAbility(new SpellCastAllTriggeredAbility(new UnifyingTheoryEffect() , new FilterSpell("a spell"), false, SetTargetPointer.PLAYER));
}
origin: magefree/mage

public GladeGnarr(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{5}{G}");
  this.subtype.add(SubType.BEAST);
  this.power = new MageInt(4);
  this.toughness = new MageInt(4);
  // Whenever a player casts a blue spell, Glade Gnarr gets +2/+2 until end of turn.
  this.addAbility(new SpellCastAllTriggeredAbility(new BoostSourceEffect(2, 2, Duration.EndOfTurn), filter, false));
}
origin: magefree/mage

public BogGnarr(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{4}{G}");
  this.subtype.add( SubType.BEAST);
  this.power = new MageInt(2);
  this.toughness = new MageInt(2);
  // Whenever a player casts a black spell, Bog Gnarr gets +2/+2 until end of turn.
  this.addAbility(new SpellCastAllTriggeredAbility(new BoostSourceEffect(2, 2, Duration.EndOfTurn), filter, false));
}
origin: magefree/mage

public OgreRecluse(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{3}{R}");
  this.subtype.add(SubType.OGRE);
  this.subtype.add(SubType.WARRIOR);
  this.power = new MageInt(5);
  this.toughness = new MageInt(4);
  // Whenever a player casts a spell, tap Ogre Recluse.
  this.addAbility(new SpellCastAllTriggeredAbility(new TapSourceEffect(), false));
}
origin: magefree/mage

public ChecksAndBalances(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{2}{U}");
  // Cast this spell only if there are three or more players in the game.
  this.addAbility(new CastOnlyIfConditionIsTrueAbility(ChecksAndBalancesCondition.instance, "Cast this spell only if there are three or more players in the game"));
  // Whenever a player casts a spell, each of that player’s opponents may discard a card. If they do, counter that spell.
  this.addAbility(new SpellCastAllTriggeredAbility(new ChecksAndBalancesEffect(), new FilterSpell("a spell"), false, SetTargetPointer.SPELL));
}
origin: magefree/mage

public ElvishHandservant(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{G}");
  this.subtype.add(SubType.ELF);
  this.subtype.add(SubType.WARRIOR);
  this.power = new MageInt(1);
  this.toughness = new MageInt(1);
  // Whenever a player casts a Giant spell, you may put a +1/+1 counter on Elvish Handservant.
  this.addAbility(new SpellCastAllTriggeredAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(1)), filter, true));
}
origin: magefree/mage

public BazaarOfWonders(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{3}{U}{U}");
  this.addSuperType(SuperType.WORLD);
  // When Bazaar of Wonders enters the battlefield, exile all cards from all graveyards.
  this.addAbility(new EntersBattlefieldTriggeredAbility(new ExileGraveyardAllPlayersEffect()));
  // Whenever a player casts a spell, counter it if a card with the same name is in a graveyard or a nontoken permanent with the same name is on the battlefield.
  this.addAbility(new SpellCastAllTriggeredAbility(new BazaarOfWondersEffect(), StaticFilters.FILTER_SPELL_A, false, SetTargetPointer.SPELL));
}
origin: magefree/mage

public QuillSlingerBoggart(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{3}{B}");
  this.subtype.add(SubType.GOBLIN);
  this.subtype.add(SubType.WARRIOR);
  this.power = new MageInt(3);
  this.toughness = new MageInt(2);
  // Whenever a player casts a Kithkin spell, you may have target player lose 1 life.
  Ability ability = new SpellCastAllTriggeredAbility(new LoseLifeTargetEffect(1), filter, true);
  ability.addTarget(new TargetPlayer());
  this.addAbility(ability);
}
origin: magefree/mage

public LapisLazuliTalisman(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{2}");
  // Whenever a player casts a blue spell, you may pay {3}. If you do, untap target permanent.
  Ability ability = new SpellCastAllTriggeredAbility(new DoIfCostPaid(new UntapTargetEffect(), new ManaCostsImpl("{3}")), filter, true);
  ability.addTarget(new TargetPermanent());
  this.addAbility(ability);
}
origin: magefree/mage

public MalachiteTalisman(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{2}");
  // Whenever a player casts a green spell, you may pay {3}. If you do, untap target permanent.
  Ability ability = new SpellCastAllTriggeredAbility(new DoIfCostPaid(new UntapTargetEffect(), new ManaCostsImpl("{3}")), filter, true);
  ability.addTarget(new TargetPermanent());
  this.addAbility(ability);
}
origin: magefree/mage

public NoosegrafMob(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{4}{B}{B}");
  this.subtype.add(SubType.ZOMBIE);
  this.power = new MageInt(0);
  this.toughness = new MageInt(0);
  // Noosegraf Mob enters the battlefield with five +1/+1 counters on it.
  this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(5)), "with five +1/+1 counters on it"));
  // Whenever a player casts a spell, remove a +1/+1 counter from Noosegraf Mob. If you do, create a 2/2 black Zombie creature token.
  this.addAbility(new SpellCastAllTriggeredAbility(new NoosegrafMobEffect(), false));
}
origin: magefree/mage

public ApothecaryInitiate(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{W}");
  this.subtype.add(SubType.KITHKIN);
  this.subtype.add(SubType.CLERIC);
  this.power = new MageInt(1);
  this.toughness = new MageInt(1);
  // Whenever a player casts a white spell, you may pay {1}. If you do, you gain 1 life.
  this.addAbility(new SpellCastAllTriggeredAbility(new DoIfCostPaid(new GainLifeEffect(1), new ManaCostsImpl("{1}")), filter, false));
}
origin: magefree/mage

public BogStriderAsh(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{3}{G}");
  this.subtype.add(SubType.TREEFOLK, SubType.SHAMAN);
  this.power = new MageInt(2);
  this.toughness = new MageInt(4);
  // Swampwalk
  this.addAbility(new SwampwalkAbility());
  
  // Whenever a player casts a Goblin spell, you may pay {G}. If you do, you gain 2 life.
  this.addAbility(new SpellCastAllTriggeredAbility(new DoIfCostPaid(new GainLifeEffect(2), new ManaCostsImpl("{G}")), filter, true));
}
origin: magefree/mage

public IntimidatorInitiate(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{R}");
  this.subtype.add(SubType.GOBLIN);
  this.subtype.add(SubType.SHAMAN);
  this.power = new MageInt(1);
  this.toughness = new MageInt(1);
  // Whenever a player casts a red spell, you may pay {1}. If you do, target creature can't block this turn.
  Ability ability = new SpellCastAllTriggeredAbility(new DoIfCostPaid(new CantBlockTargetEffect(Duration.EndOfTurn), new GenericManaCost(1)), filter, true, rule);
  ability.addTarget(new TargetCreaturePermanent());
  this.addAbility(ability);
  
}
mage.abilities.commonSpellCastAllTriggeredAbility<init>

Popular methods of SpellCastAllTriggeredAbility

  • checkTrigger
  • getControllerId
  • getEffects
  • getSourceId

Popular in Java

  • Parsing JSON documents to java classes using gson
  • setRequestProperty (URLConnection)
  • compareTo (BigDecimal)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • UnknownHostException (java.net)
    Thrown when a hostname can not be resolved.
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
  • SQLException (java.sql)
    An exception that indicates a failed JDBC operation. It provides the following information about pro
  • MessageFormat (java.text)
    Produces concatenated messages in language-neutral way. New code should probably use java.util.Forma
  • Vector (java.util)
    Vector is an implementation of List, backed by an array and synchronized. All optional operations in
  • Base64 (org.apache.commons.codec.binary)
    Provides Base64 encoding and decoding as defined by RFC 2045.This class implements section 6.8. Base
  • Sublime Text for Python
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now