[EMN] Added additional 6/27 spoilers to mtg-cards-data.txt Fixed Identity Thief's translated name. Implemented several new EMN cards. Fixed rules text on several tap and don't untap cards.

This commit is contained in:
fireshoes 2016-06-27 19:33:05 -05:00
parent 744e303265
commit fd29307ad4
18 changed files with 1023 additions and 15 deletions

View file

@ -31,6 +31,8 @@ import java.util.UUID;
import mage.abilities.Ability;
import mage.abilities.condition.Condition;
import mage.game.Game;
import mage.players.Player;
import mage.players.PlayerList;
/**
*
@ -38,7 +40,7 @@ import mage.game.Game;
*/
public class TenOrLessLifeCondition implements Condition {
public static enum CheckType { AN_OPPONENT, CONTROLLER, TARGET_OPPONENT };
public static enum CheckType { AN_OPPONENT, CONTROLLER, TARGET_OPPONENT, EACH_PLAYER };
private final CheckType type;
@ -62,6 +64,19 @@ public class TenOrLessLifeCondition implements Condition {
case TARGET_OPPONENT:
//TODO: Implement this.
break;
case EACH_PLAYER:
int maxLife = 0;
PlayerList playerList = game.getState().getPlayersInRange(source.getControllerId(), game);
for ( UUID pid : playerList ) {
Player p = game.getPlayer(pid);
if (p != null) {
if (maxLife < p.getLife()) {
maxLife = p.getLife();
}
}
}
conditionApplies |= maxLife <= 10;
break;
}
return conditionApplies;