Codota Logo
ReplacementEffectImpl
Code IndexAdd Codota to your IDE (free)

How to use
ReplacementEffectImpl
in
mage.abilities.effects

Best Java code snippets using mage.abilities.effects.ReplacementEffectImpl (Showing top 7 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
StringBuilder s =
  • Codota Iconnew StringBuilder()
  • Codota Iconnew StringBuilder(32)
  • Codota IconString str;new StringBuilder(str)
  • Smart code suggestions by Codota
}
origin: magefree/mage

@Override
public void init(Ability source, Game game) {
  super.init(source, game);
  if (commanderId == null) {
    throw new IllegalArgumentException("commanderId has to be set");
  }
}
origin: magefree/mage

@Override
public void init(Ability source, Game game) {
  super.init(source, game);
  if (amountToPreventDynamic != null) {
    amountToPrevent = amountToPreventDynamic.calculate(game, source, this);
  }
}
origin: magefree/mage

@Override
public void init(Ability source, Game game) {
  this.damageSource.choose(Outcome.PreventDamage, source.getControllerId(), source.getSourceId(), game);
  super.init(source, game);
}
origin: magefree/mage

@Override
public void init(Ability source, Game game) {
  this.target.choose(Outcome.PreventDamage, source.getControllerId(), source.getSourceId(), game);
  super.init(source, game);
}
origin: magefree/mage

@Override
public void init(Ability source, Game game) {
  this.wonFlip = game.getPlayer(source.getControllerId()).flipCoin(source, game, true);
  super.init(source, game);
}
origin: magefree/mage

@Override
public void init(Ability source, Game game) {
  super.init(source, game);
  if (baseCondition instanceof LockedInCondition) {
    condition = new FixedCondition(((LockedInCondition) baseCondition).getBaseCondition().apply(game, source));
  } else {
    condition = baseCondition;
  }
  effect.setTargetPointer(this.targetPointer);
  effect.init(source, game);
  if (otherwiseEffect != null) {
    otherwiseEffect.setTargetPointer(this.targetPointer);
    otherwiseEffect.init(source, game);
  }
  initDone = true;
}
origin: magefree/mage

@Override
public void init(Ability source, Game game) {
  super.init(source, game);
  Player player = game.getPlayer(getTargetPointer().getFirst(game, source));
  Permanent mageObject = game.getPermanentOrLKIBattlefield(source.getSourceId());
  if (player != null && mageObject != null) {
    ChoiceColor choice = new ChoiceColor();
    if (!player.choose(outcome, choice, game)) {
      discard();
      return;
    }
    if (!game.isSimulation()) {
      game.informPlayers(mageObject.getLogName() + ": " + player.getLogName() + " has chosen " + choice.getChoice());
    }
    game.getState().setValue(mageObject.getId() + "_color", choice.getColor());
    mageObject.addInfo("chosen color", CardUtil.addToolTipMarkTags("Chosen color: " + choice.getChoice()), game);
  }
}
mage.abilities.effectsReplacementEffectImpl

Most used methods

  • init

Popular in Java

  • Making http post requests using okhttp
  • setRequestProperty (URLConnection)
  • putExtra (Intent)
  • compareTo (BigDecimal)
    Compares this BigDecimal with the specified BigDecimal. Two BigDecimal objects that are equal in val
  • Menu (java.awt)
  • URI (java.net)
    Represents a Uniform Resource Identifier (URI) reference. Aside from some minor deviations noted bel
  • Map (java.util)
    A Map is a data structure consisting of a set of keys and values in which each key is mapped to a si
  • JarFile (java.util.jar)
    JarFile is used to read jar entries and their associated data from jar files.
  • FileUtils (org.apache.commons.io)
    General file manipulation utilities. Facilities are provided in the following areas: * writing to a
  • IsNull (org.hamcrest.core)
    Is the value null?
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now