congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
OpponentsLostLifeCount.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
mage.abilities.dynamicvalue.common.OpponentsLostLifeCount
constructor

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

origin: magefree/mage

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

@Override
public boolean apply(Game game, Ability source, Ability abilityToModify) {
  Ability spellAbility = abilityToModify;
  if (spellAbility != null) {
    OpponentsLostLifeCount dynamicValue = new OpponentsLostLifeCount();
    int amount = dynamicValue.calculate(game, source, this);
    if (amount > 0) {
      CardUtil.reduceCost(spellAbility, amount);
      return true;
    }
  }
  return false;
}
origin: magefree/mage

@Override
public Mana produceMana(boolean netMana, Game game, Ability source) {
  return Mana.RedMana(new OpponentsLostLifeCount().calculate(game, source, this));
}
origin: magefree/mage

  @Override
  public boolean applies(GameEvent event, Ability source, Game game) {
    if (event.getSourceId().equals(source.getSourceId())) {
      if (new OpponentsLostLifeCount().calculate(game, source, this) == 0) {
        return true;
      }
    }
    return false;
  }
}
origin: magefree/mage

@Override
public boolean apply(Game game, Ability source) {
  Permanent permanent = game.getPermanentEntering(source.getSourceId());
  if (permanent != null) {
    int oll = new OpponentsLostLifeCount().calculate(game, source, this);
    if (oll > 0) {
      permanent.addCounters(CounterType.P1P1.createInstance(oll), source, game);
    }
    return true;
  }
  return false;
}
origin: magefree/mage

@Override
public boolean apply(Game game, Ability source) {
  Permanent permanent = game.getPermanentEntering(source.getSourceId());
  if (permanent != null) {
    int oll = new OpponentsLostLifeCount().calculate(game, source, this);
    if (oll > 0) {
      permanent.addCounters(CounterType.P1P1.createInstance(oll), source, game);
    }
    return true;
  }
  return false;
}
mage.abilities.dynamicvalue.commonOpponentsLostLifeCount<init>

Popular methods of OpponentsLostLifeCount

  • calculate

Popular in Java

  • Finding current android device location
  • addToBackStack (FragmentTransaction)
  • getContentResolver (Context)
  • onRequestPermissionsResult (Fragment)
  • BufferedWriter (java.io)
    Wraps an existing Writer and buffers the output. Expensive interaction with the underlying reader is
  • SecureRandom (java.security)
    This class generates cryptographically secure pseudo-random numbers. It is best to invoke SecureRand
  • PriorityQueue (java.util)
    A PriorityQueue holds elements on a priority heap, which orders the elements according to their natu
  • TreeMap (java.util)
    Walk the nodes of the tree left-to-right or right-to-left. Note that in descending iterations, next
  • Filter (javax.servlet)
    A filter is an object that performs filtering tasks on either the request to a resource (a servlet o
  • StringUtils (org.apache.commons.lang)
    Operations on java.lang.String that arenull safe. * IsEmpty/IsBlank - checks if a String contains
  • 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