Examples of DamagePlaneswalkerEvent


Examples of mage.game.events.DamagePlaneswalkerEvent

  public void removeAllDamage(Game game) {
    damage = 0;
  }

  protected int damagePlaneswalker(int damage, UUID sourceId, Game game, boolean preventable, boolean combat) {
    GameEvent event = new DamagePlaneswalkerEvent(objectId, sourceId, controllerId, damage, preventable, combat);
    if (!game.replaceEvent(event)) {
      int actualDamage = event.getAmount();
      if (actualDamage > 0) {
        if (event.getAmount() > this.loyalty.getValue()) {
          actualDamage = this.loyalty.getValue();
        }
        this.loyalty.boostValue(-actualDamage);
        game.fireEvent(new DamagedPlaneswalkerEvent(objectId, sourceId, controllerId, actualDamage, combat));
        return actualDamage;
View Full Code Here

Examples of mage.game.events.DamagePlaneswalkerEvent

        damage = 0;
        deathtouched = false;
    }

    protected int damagePlaneswalker(int damage, UUID sourceId, Game game, boolean preventable, boolean combat, boolean markDamage, ArrayList<UUID> appliedEffects) {
        GameEvent event = new DamagePlaneswalkerEvent(objectId, sourceId, controllerId, damage, preventable, combat);
        event.setAppliedEffects(appliedEffects);
        if (!game.replaceEvent(event)) {
            int actualDamage = event.getAmount();
            if (actualDamage > 0) {
                int countersToRemove = actualDamage;
                if (countersToRemove > getCounters().getCount(CounterType.LOYALTY)) {
                    countersToRemove = getCounters().getCount(CounterType.LOYALTY);
                }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.