- little fixes

This commit is contained in:
Jeff 2019-03-06 17:11:45 -06:00
parent ee3f592186
commit 5220e44b16
2 changed files with 13 additions and 7 deletions

View file

@ -39,13 +39,15 @@ public class LoseLifeTargetEffect extends OneShotEffect {
@Override
public boolean apply(Game game, Ability source) {
boolean applied = false;
for (UUID playerId : targetPointer.getTargets(game, source)) {
Player player = game.getPlayer(playerId);
if (player != null) {
player.loseLife(amount.calculate(game, source, this), game, false);
if (player != null
&& player.loseLife(amount.calculate(game, source, this), game, false) > 0) {
applied = true;
}
}
return true;
return applied;
}
@Override