[Un-cards] DeckLimit keyword + Cardboard Carapace

This commit is contained in:
Adam Pantel
2021-03-06 15:58:01 -05:00
parent 0312e54590
commit acb21b2a28
10 changed files with 43 additions and 14 deletions

View File

@@ -1846,7 +1846,7 @@ public class Card extends GameEntity implements Comparable<Card>, IHasSVars {
s.append(" on it.");
}
sbLong.append(s).append("\r\n");
} else if (keyword.startsWith("Protection:")) {
} else if (keyword.startsWith("Protection:") || keyword.startsWith("DeckLimit")) {
final String[] k = keyword.split(":");
sbLong.append(k[2]).append("\r\n");
} else if (keyword.startsWith("Creatures can't attack unless their controller pays")) {
@@ -1966,8 +1966,7 @@ public class Card extends GameEntity implements Comparable<Card>, IHasSVars {
|| keyword.equals("Foretell") // for the ones without cost
|| keyword.equals("Hideaway") || keyword.equals("Ascend")
|| keyword.equals("Totem armor") || keyword.equals("Battle cry")
|| keyword.equals("Devoid") || keyword.equals("Riot")
|| keyword.equals("Megalegendary")){
|| keyword.equals("Devoid") || keyword.equals("Riot")){
sbLong.append(keyword).append(" (").append(inst.getReminderText()).append(")");
} else if (keyword.startsWith("Partner:")) {
final String[] k = keyword.split(":");
@@ -2483,6 +2482,9 @@ public class Card extends GameEntity implements Comparable<Card>, IHasSVars {
sbBefore.append(" You may choose new targets for the copies.");
}
sbBefore.append(")\r\n");
} else if (keyword.startsWith("DeckLimit")) {
final String[] k = keyword.split(":");
sbBefore.append(k[2]).append("\r\n");
}
} catch (Exception e) {
String msg = "Card:abilityTextInstantSorcery: crash in Keyword parsing";

View File

@@ -92,7 +92,6 @@ public enum Keyword {
LIFELINK("Lifelink", SimpleKeyword.class, true, "Damage dealt by this creature also causes its controller to gain that much life."),
LIVING_WEAPON("Living weapon", SimpleKeyword.class, true, "When this Equipment enters the battlefield, create a 0/0 black Germ creature token, then attach this to it."),
MADNESS("Madness", KeywordWithCost.class, false, "If you discard this card, discard it into exile. When you do, cast it for %s or put it into your graveyard."),
MEGALEGENDARY("Megalegendary", SimpleKeyword.class, true, "Your deck can have only one copy of this card."),
MELEE("Melee", SimpleKeyword.class, false, "Whenever this creature attacks, it gets +1/+1 until end of turn for each opponent you attacked this combat."),
MENTOR("Mentor", SimpleKeyword.class, false, "Whenever this creature attacks, put a +1/+1 counter on target attacking creature with lesser power."),
MENACE("Menace", SimpleKeyword.class, true, "This creature can't be blocked except by two or more creatures."),