congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
CantBeBlockedByAllSourceEffect
Code IndexAdd Tabnine to your IDE (free)

How to use
CantBeBlockedByAllSourceEffect
in
mage.abilities.effects.common.combat

Best Java code snippets using mage.abilities.effects.common.combat.CantBeBlockedByAllSourceEffect (Showing top 4 results out of 315)

origin: magefree/mage

  @Override
  public CantBeBlockedByAllSourceEffect copy() {
    return new CantBeBlockedByAllSourceEffect(this);
  }
}
origin: magefree/mage

public ShroudedSerpent(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{4}{U}{U}{U}");
  this.subtype.add(SubType.SERPENT);
  this.power = new MageInt(4);
  this.toughness = new MageInt(4);
  
  // Whenever Shrouded Serpent attacks, defending player may pay {4}. If he or she doesn't, Shrouded Serpent can't be blocked this turn.
  this.addAbility(new AttacksTriggeredAbility(
      new DoUnlessTargetPlayerOrTargetsControllerPaysEffect(new CantBeBlockedByAllSourceEffect(new FilterCreaturePermanent(), Duration.EndOfCombat), new ManaCostsImpl("{4}")), 
      false, 
      "Whenever {this} attacks, defending player may pay {4}. If he or she doesn't, {this} can't be blocked this turn.", 
      SetTargetPointer.PLAYER));
}
origin: magefree/mage

  @Override
  public boolean apply(Game game, Ability source) {
    Player player = game.getPlayer(source.getControllerId());
    if (player != null) {
      Card card = player.getLibrary().getFromTop(game);
      if (card != null) {
        player.moveCards(card, Zone.GRAVEYARD, source, game);
        if (card.isLand()) {
          game.addEffect(new CantBeBlockedByAllSourceEffect(StaticFilters.FILTER_PERMANENT_CREATURES, Duration.EndOfTurn), source);
        }
      }
      return true;
    }
    return false;
  }
}
origin: magefree/mage

public RhonassStalwart(UUID ownerId, CardSetInfo setInfo) {
  super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{G}");
  this.subtype.add(SubType.HUMAN);
  this.subtype.add(SubType.WARRIOR);
  this.power = new MageInt(2);
  this.toughness = new MageInt(2);
  // You may exert Rhonas's Stalwart as it attacks. When you do, it gets +1/+1 until end of turn and can't be blocked by creatures with power 2 or less this turn.
  Effect effect = new BoostSourceEffect(1, 1, Duration.EndOfTurn);
  effect.setText("it gets +1/+1");
  BecomesExertSourceTriggeredAbility ability = new BecomesExertSourceTriggeredAbility(effect);
  effect = new CantBeBlockedByAllSourceEffect(filter, Duration.EndOfTurn);
  effect.setText("and can't be blocked by creatures with power 2 or less this turn");
  ability.addEffect(effect);
  this.addAbility(new ExertAbility(ability));
}
mage.abilities.effects.common.combatCantBeBlockedByAllSourceEffect

Most used methods

  • <init>

Popular in Java

  • Parsing JSON documents to java classes using gson
  • onCreateOptionsMenu (Activity)
  • scheduleAtFixedRate (Timer)
  • runOnUiThread (Activity)
  • FileOutputStream (java.io)
    An output stream that writes bytes to a file. If the output file exists, it can be replaced or appen
  • ConnectException (java.net)
    A ConnectException is thrown if a connection cannot be established to a remote host on a specific po
  • MalformedURLException (java.net)
    This exception is thrown when a program attempts to create an URL from an incorrect specification.
  • URLConnection (java.net)
    A connection to a URL for reading or writing. For HTTP connections, see HttpURLConnection for docume
  • Options (org.apache.commons.cli)
    Main entry-point into the library. Options represents a collection of Option objects, which describ
  • Loader (org.hibernate.loader)
    Abstract superclass of object loading (and querying) strategies. This class implements useful common
  • Github Copilot alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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