Examples of loseLife()


Examples of mage.players.Player.loseLife()

                    amount = power;
                }
            }

            if (amount > 0) {
                targetPlayer.loseLife(amount, game);
                player.gainLife(amount, game);
            }
            return true;
        }
        return false;
View Full Code Here

Examples of mage.players.Player.loseLife()

                creature = (Permanent) game.getLastKnownInformation(source.getSourceId(), Zone.BATTLEFIELD);
            }
            if (creature != null) {
                Player player = game.getPlayer(creature.getControllerId());
                if (player != null) {
                    player.loseLife(amount.calculate(game, source, this), game);
                    return true;
                }
            }
        }
        return false;
View Full Code Here

Examples of mage.players.Player.loseLife()

            }
           
            int amount = (player.getLife() + 1)/2;
            if(amount > 0)
            {
                player.loseLife(amount, game);
            }
           
            Card cardToExile = game.getCard(source.getSourceId());
            if(cardToExile != null)
            {
View Full Code Here

Examples of mage.players.Player.loseLife()

        Player controller = game.getPlayer(source.getControllerId());
        if (controller != null) {
            ActivatedLoyaltyAbilityWatcher watcher = (ActivatedLoyaltyAbilityWatcher) game.getState().getWatchers().get("ActivatedLoyaltyAbilityWatcher");
            if (watcher != null) {
                if (!watcher.activatedLayaltyAbility(source.getControllerId())) {
                    controller.loseLife(2, game);
                }
            }
        }
        return false;
    }
View Full Code Here

Examples of mage.players.Player.loseLife()

    public boolean apply(Game game, Ability source) {
        Player player = game.getPlayer(source.getFirstTarget());
        if (player != null) {
            int amount = game.getLife();
            if (amount < 0) {
                player.loseLife(amount, game);
                return true;
            }
            if (amount > 0) {
                player.gainLife(amount, game);
                return true;
View Full Code Here

Examples of mage.players.Player.loseLife()

    @Override
    public boolean apply(Game game, Ability source) {
        int damage = 0;
        for (UUID opponentId: game.getOpponents(source.getControllerId())) {
            Player opponent = game.getPlayer(opponentId);
            damage += opponent.loseLife(4, game);
        }
        game.getPlayer(source.getControllerId()).gainLife(damage, game);
        return true;
    }
View Full Code Here

Examples of mage.players.Player.loseLife()

                break;
            }
        }
       
        controller.revealCards(sourceObject.getLogName(), cards, game);
        controller.loseLife(cards.size(), game);
       
        return true;
    }
}
View Full Code Here

Examples of mage.players.Player.loseLife()

            }
           
            //You lose half your life, rounded up
            int amount = (player.getLife() + 1) / 2;
            if (amount > 0) {
                player.loseLife(amount, game);
            }

            return true;
        }
        return false;
View Full Code Here

Examples of mage.players.Player.loseLife()

   
    @Override
    public boolean apply(Game game, Ability source) {
        Player player = game.getPlayer(this.getTargetPointer().getFirst(game, source));
        if (player != null) {
            player.loseLife(10, game);
        }
        return super.apply(game, source);
    }
}
View Full Code Here

Examples of mage.players.Player.loseLife()

    @Override
    public boolean apply(Game game, Ability source) {
        Player player = game.getPlayer(source.getControllerId());
        Permanent target = game.getPermanentOrLKIBattlefield(this.getTargetPointer().getFirst(game, source));
        if (player != null && target != null) {
            player.loseLife(target.getToughness().getValue(), game);
            return true;
        }
        return false;
    }
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.