- Conspiracy: Added Marchesa, the Black Rose

This commit is contained in:
swordshine
2014-05-15 09:01:32 +00:00
parent 8b33b78831
commit 1cc02b58c1
2 changed files with 16 additions and 3 deletions

View File

@@ -3260,6 +3260,21 @@ public class CardFactoryUtil {
ripplePos = hasKeyword(card, "Ripple", n + 1);
} // Ripple
final int dethrone = card.getKeywordAmount("Dethrone");
for (int i = 0; i < dethrone; i++) {
final StringBuilder trigScript = new StringBuilder(
"Mode$ Attacks | ValidCard$ Card.Self | Attacked$ Player.withMostLife | "
+ "TriggerZones$ Battlefield | Execute$ DethroneCounters | TriggerDescription$"
+ " Dethrone (Whenever this creature attacks the player with the most life or "
+ "tied for the most life, put a +1/+1 counter on it.)");
final String abString = "DB$ PutCounter | Defined$ Self | CounterType$ P1P1 | "
+ "CounterNum$ 1";
card.setSVar("DethroneCounters", abString);
final Trigger cascadeTrigger = TriggerHandler.parseTrigger(trigScript.toString(), card, true);
card.addTrigger(cascadeTrigger);
} // Cascade
}

View File

@@ -2445,14 +2445,12 @@ public class Player extends GameEntity implements Comparable<Player> {
} else if (property.startsWith("withMost")) {
if (property.substring(8).equals("Life")) {
int highestLife = this.getLife(); // Negative base just in case a few Lich's are running around
Player healthiest = this;
for (final Player p : game.getPlayers()) {
if (p.getLife() > highestLife) {
highestLife = p.getLife();
healthiest = p;
}
}
if (!this.equals(healthiest)) {
if (this.getLife() != highestLife) {
return false;
}
}