MKM - Case stuff (#4566)

This commit is contained in:
Northmoc
2024-01-21 04:42:28 -05:00
committed by GitHub
parent 8276b99a39
commit aa847acf04
7 changed files with 46 additions and 10 deletions

View File

@@ -29,6 +29,7 @@ public class AlterAttributeEffect extends SpellAbilityEffect {
break; break;
} }
} }
c.updateAbilityTextForView();
} }
} }
} }

View File

@@ -308,9 +308,9 @@ public class FCardImageRenderer {
int textY = typeY + typeBoxHeight; int textY = typeY + typeBoxHeight;
int ptY = textY + textBoxHeight; int ptY = textY + textBoxHeight;
// Adjust layout for Saga, Class and Dungeon cards // Adjust layout for Saga, Class, Case and Dungeon cards
boolean isSaga = state.getType().hasSubtype("Saga"); boolean isSaga = state.getType().hasSubtype("Saga");
boolean isClass = state.getType().hasSubtype("Class"); boolean isClass = state.getType().hasSubtype("Class") || state.getType().hasSubtype("Case");
boolean isDungeon = state.getType().isDungeon(); boolean isDungeon = state.getType().isDungeon();
if (isSaga || isClass || isDungeon) { if (isSaga || isClass || isDungeon) {
// Move type line to the bottom // Move type line to the bottom

View File

@@ -108,7 +108,7 @@ public class CardImageRenderer {
if (isFaceDown && altState && card.isSplitCard()) if (isFaceDown && altState && card.isSplitCard())
state = card.getLeftSplitState(); state = card.getLeftSplitState();
boolean isSaga = state.getType().hasSubtype("Saga"); boolean isSaga = state.getType().hasSubtype("Saga");
boolean isClass = state.getType().hasSubtype("Class"); boolean isClass = state.getType().hasSubtype("Class") || state.getType().hasSubtype("Case");
boolean isDungeon = state.getType().isDungeon(); boolean isDungeon = state.getType().isDungeon();
boolean drawDungeon = isDungeon && CardRenderer.getCardArt(card) != null; boolean drawDungeon = isDungeon && CardRenderer.getCardArt(card) != null;
@@ -325,12 +325,12 @@ public class CardImageRenderer {
private static void drawArt(CardView cv, Graphics g, float x, float y, float w, float h, boolean altState, boolean isFaceDown) { private static void drawArt(CardView cv, Graphics g, float x, float y, float w, float h, boolean altState, boolean isFaceDown) {
boolean isSaga = cv.getCurrentState().getType().hasSubtype("Saga"); boolean isSaga = cv.getCurrentState().getType().hasSubtype("Saga");
boolean isClass = cv.getCurrentState().getType().hasSubtype("Class"); boolean isClass = cv.getCurrentState().getType().hasSubtype("Class") || cv.getCurrentState().getType().hasSubtype("Case");
boolean isDungeon = cv.getCurrentState().getType().isDungeon(); boolean isDungeon = cv.getCurrentState().getType().isDungeon();
ColorSet colorSet = cv.getCurrentState().getColors(); ColorSet colorSet = cv.getCurrentState().getColors();
if (altState && cv.hasAlternateState()) { if (altState && cv.hasAlternateState()) {
isSaga = cv.getAlternateState().getType().hasSubtype("Saga"); isSaga = cv.getAlternateState().getType().hasSubtype("Saga");
isClass = cv.getAlternateState().getType().hasSubtype("Class"); isClass = cv.getAlternateState().getType().hasSubtype("Class") || cv.getAlternateState().getType().hasSubtype("Case");
isDungeon = cv.getAlternateState().getType().isDungeon(); isDungeon = cv.getAlternateState().getType().isDungeon();
colorSet = cv.getAlternateState().getColors(); colorSet = cv.getAlternateState().getColors();
} }
@@ -376,7 +376,8 @@ public class CardImageRenderer {
altArt = CardRenderer.getAlternateCardArt(cv.getAlternateState().getImageKey(), cv.getAlternateState().isPlaneswalker()); altArt = CardRenderer.getAlternateCardArt(cv.getAlternateState().getImageKey(), cv.getAlternateState().isPlaneswalker());
else { else {
altArt = CardRenderer.getCardArt(cv.getAlternateState().getImageKey(), cv.isSplitCard(), cv.getAlternateState().isPlane() || cv.getAlternateState().isPhenomenon(), cv.getText().contains("Aftermath"), altArt = CardRenderer.getCardArt(cv.getAlternateState().getImageKey(), cv.isSplitCard(), cv.getAlternateState().isPlane() || cv.getAlternateState().isPhenomenon(), cv.getText().contains("Aftermath"),
cv.getAlternateState().getType().hasSubtype("Saga"), cv.getAlternateState().getType().hasSubtype("Class"), cv.getAlternateState().getType().isDungeon(), cv.isFlipCard(), cv.getAlternateState().isPlaneswalker(), CardRenderer.isModernFrame(cv), cv.getAlternateState().getType().isBattle()); cv.getAlternateState().getType().hasSubtype("Saga"), cv.getAlternateState().getType().hasSubtype("Class") || cv.getAlternateState().getType().hasSubtype("Case"), cv.getAlternateState().getType().isDungeon(),
cv.isFlipCard(), cv.getAlternateState().isPlaneswalker(), CardRenderer.isModernFrame(cv), cv.getAlternateState().getType().isBattle());
} }
} }
} }

View File

@@ -3,10 +3,9 @@ ManaCost:U
Types:Enchantment Case Types:Enchantment Case
T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigInvestigate | TriggerDescription$ When this Case enters the battlefield, investigate. (Create a colorless Clue artifact token with "{2}, Sacrifice this artifact: Draw a card.") T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigInvestigate | TriggerDescription$ When this Case enters the battlefield, investigate. (Create a colorless Clue artifact token with "{2}, Sacrifice this artifact: Draw a card.")
SVar:TrigInvestigate:DB$ Investigate SVar:TrigInvestigate:DB$ Investigate
T:Mode$ Phase | Phase$ End of Turn | ValidPlayer$ You | TriggerZones$ Battlefield | IsPresent$ Artifact.YouCtrl | PresentZone$ Battlefield | PresentCompare$ GE3 | CheckSVar$ Solved | SVarCompare$ GE1 | Execute$ SolveFalcon | TriggerDescription$ To solve - You control three or more artifacts. T:Mode$ Phase | Phase$ End of Turn | ValidPlayer$ You | TriggerZones$ Battlefield | IsPresent$ Artifact.YouCtrl | PresentCompare$ GE3 | IsPresent2$ Card.Self+IsUnsolved | Execute$ SolveFalcon | TriggerDescription$ To solve You control three or more artifacts. (If unsolved, solve at the beginning of your end step.)
SVar:SolveFalcon:DB$ AlterAttribute | Defined$ Self | Attributes$ Solved SVar:SolveFalcon:DB$ AlterAttribute | Defined$ Self | Attributes$ Solved
A:AB$ PutCounter | Cost$ 2 U Sac<1/CARDNAME> | ValidTgts$ Artifact.nonCreature | TgtPrompt$ Select target noncreature artifact | Activation$ Solved | CounterType$ P1P1 | CounterNum$ 4 | SubAbility$ DBAnimate | PrecostDesc$ Solved - | SpellDescription$ Put four +1/+1 counters on target noncreature artifact. It becomes a 0/0 Bird creature with flying in addition to its other types. A:AB$ PutCounter | Cost$ 2 U Sac<1/CARDNAME/this Case> | ValidTgts$ Artifact.nonCreature | TgtPrompt$ Select target noncreature artifact | Activation$ Solved | CounterType$ P1P1 | CounterNum$ 4 | SubAbility$ DBAnimate | PrecostDesc$ Solved | SpellDescription$ Put four +1/+1 counters on target noncreature artifact. It becomes a 0/0 Bird creature with flying in addition to its other types.
SVar:DBAnimate:DB$ Animate | Defined$ ParentTarget | Power$ 0 | Toughness$ 0 | Types$ Creature,Bird | Keywords$ Flying | Duration$ Permanent SVar:DBAnimate:DB$ Animate | Defined$ ParentTarget | Power$ 0 | Toughness$ 0 | Types$ Creature,Bird | Keywords$ Flying | Duration$ Permanent
SVar:Solved:Count$Valid Card.Self+IsUnsolved
DeckNeeds:Type$Artifact DeckNeeds:Type$Artifact
Oracle:When this Case enters the battlefield, investigate. (Create a Clue token. Its an artifact with {2}, Sacrifice this artifact: Draw a card.)\nTo solve — You control three or more artifacts. (If unsolved, solve at the beginning of your end step.)\nSolved — {2}{U}, Sacrifice this Case: Put four +1/+1 counters on target noncreature artifact. It becomes a 0/0 Bird creature with flying in addition to its other types. Oracle:When this Case enters the battlefield, investigate. (Create a Clue token. It's an artifact with "{2}, Sacrifice this artifact: Draw a card.")\nTo solve — You control three or more artifacts. (If unsolved, solve at the beginning of your end step.)\nSolved — {2}{U}, Sacrifice this Case: Put four +1/+1 counters on target noncreature artifact. It becomes a 0/0 Bird creature with flying in addition to its other types.

View File

@@ -0,0 +1,11 @@
Name:Case of the Gorgon's Kiss
ManaCost:B
Types:Enchantment Case
T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigDestroy | TriggerDescription$ When this Case enters the battlefield, destroy up to one target creature that was dealt damage this turn.
SVar:TrigDestroy:DB$ Destroy | TargetMin$ 0 | TargetMax$ 1 | ValidTgts$ Creature.wasDealtDamageThisTurn | TgtPrompt$ Select up to one target creature that was dealt damage this turn
T:Mode$ Phase | Phase$ End of Turn | ValidPlayer$ You | TriggerZones$ Battlefield | CheckSVar$ Count$ThisTurnEntered_Graveyard_Creature | SVarCompare$ GE3 | IsPresent$ Card.Self+IsUnsolved | Execute$ Solved | TriggerDescription$ To solve Three or more creature cards were put into graveyards from anywhere this turn. (If unsolved, solve at the beginning of your end step.)
SVar:Solved:DB$ AlterAttribute | Defined$ Self | Attributes$ Solved
S:Mode$ Continuous | Affected$ Card.Self+IsSolved | AddType$ Creature & Gorgon | SetPower$ 4 | SetToughness$ 4 | AddKeyword$ Deathtouch & Lifelink | Description$ Solved This Case is a 4/4 Gorgon creature with deathtouch and lifelink in addition to its other types.
DeckHints:Ability$Sacrifice|Discard
DeckHas:Ability$LifeGain
Oracle:When this Case enters the battlefield, destroy up to one target creature that was dealt damage this turn.\nTo solve Three or more creature cards were put into graveyards from anywhere this turn. (If unsolved, solve at the beginning of your end step.)\nSolved This Case is a 4/4 Gorgon creature with deathtouch and lifelink in addition to its other types.

View File

@@ -0,0 +1,14 @@
Name:Case of the Pilfered Proof
ManaCost:1 W
Types:Enchantment Case
T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Detective.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigPutCounter | TriggerDescription$ Whenever a Detective enters the battlefield under your control and whenever a Detective you control is turned face up, put a +1/+1 counter on it.
T:Mode$ TurnFaceUp | ValidCard$ Detective.YouCtrl | Execute$ TrigPutCounter | TriggerZones$ Battlefield | Secondary$ True | TriggerDescription$ Whenever a Detective enters the battlefield under your control and whenever a Detective you control is turned face up, put a +1/+1 counter on it.
SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ P1P1 | CounterNum$ 1
T:Mode$ Phase | Phase$ End of Turn | ValidPlayer$ You | TriggerZones$ Battlefield | IsPresent$ Detective.YouCtrl | PresentCompare$ GE3 | IsPresent2$ Card.Self+IsUnsolved | Execute$ Solved | TriggerDescription$ To solve You control three or more Detectives. (If unsolved, solve at the beginning of your end step.)
SVar:Solved:DB$ AlterAttribute | Defined$ Self | Attributes$ Solved
R:Event$ CreateToken | IsPresent$ Card.Self+IsSolved | ActiveZones$ Battlefield | ValidToken$ Card.YouCtrl | ReplaceWith$ DBReplace | Description$ Solved If one or more tokens would be created under your control, those tokens plus a Clue token are created instead. (It's an artifact with "{2}, Sacrifice this artifact: Draw a card.")
SVar:DBReplace:DB$ ReplaceToken | Type$ AddToken | Amount$ 1 | ValidCard$ Card.YouCtrl | TokenScript$ c_a_clue_draw
DeckNeeds:Type$Detective
DeckHas:Ability$Counters|Token|Sacrifice & Type$Artifact|Clue
DeckHints:Ability$Token
Oracle:Whenever a Detective enters the battlefield under your control and whenever a Detective you control is turned face up, put a +1/+1 counter on it.\nTo solve You control three or more Detectives. (If unsolved, solve at the beginning of your end step.)\nSolved If one or more tokens would be created under your control, those tokens plus a Clue token are created instead. (It's an artifact with "{2}, Sacrifice this artifact: Draw a card.")

View File

@@ -0,0 +1,10 @@
Name:Case of the Ransacked Lab
ManaCost:2 U
Types:Enchantment Case
S:Mode$ ReduceCost | ValidCard$ Instant,Sorcery | Type$ Spell | Activator$ You | Amount$ 1 | Description$ Instant and sorcery spells you cast cost {1} less to cast.
T:Mode$ Phase | Phase$ End of Turn | ValidPlayer$ You | TriggerZones$ Battlefield | CheckSVar$ Count$ThisTurnCast_Instant.YouCtrl,Sorcery.YouCtrl | SVarCompare$ GE4 | IsPresent$ Card.Self+IsUnsolved | Execute$ Solved | TriggerDescription$ To solve You've cast four or more instant and sorcery spells this turn. (If unsolved, solve at the beginning of your end step.)
SVar:Solved:DB$ AlterAttribute | Defined$ Self | Attributes$ Solved
T:Mode$ SpellCast | IsPresent$ Card.Self+IsSolved | ValidCard$ Instant,Sorcery | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigDraw | TriggerDescription$ Solved Whenever you cast an instant or sorcery spell, draw a card.
SVar:TrigDraw:DB$ Draw
DeckNeed:Type$Instant|Sorcery
Oracle:Instant and sorcery spells you cast cost {1} less to cast.\nTo solve You've cast four or more instant and sorcery spells this turn. (If unsolved, solve at the beginning of your end step.)\nSolved Whenever you cast an instant or sorcery spell, draw a card.