mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 12:48:00 +00:00
NEO: initial support for "modified" property
This commit is contained in:
committed by
Hans Mackowiak
parent
5e16d91e83
commit
06e95e0293
@@ -3474,6 +3474,13 @@ public class Card extends GameEntity implements Comparable<Card>, IHasSVars {
|
|||||||
runUnattachCommands();
|
runUnattachCommands();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public final boolean isModified() {
|
||||||
|
if (this.isEquipped() || this.hasCounters()) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return Iterables.any(this.getEnchantedBy(), CardPredicates.isController(this.getController()));
|
||||||
|
}
|
||||||
|
|
||||||
public final void setType(final CardType type0) {
|
public final void setType(final CardType type0) {
|
||||||
currentState.setType(type0);
|
currentState.setType(type0);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1328,6 +1328,10 @@ public class CardProperty {
|
|||||||
if (card.isEquipping()) {
|
if (card.isEquipping()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
} else if (property.startsWith("modified")) {
|
||||||
|
if (!card.isModified()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
} else if (property.startsWith("token")) {
|
} else if (property.startsWith("token")) {
|
||||||
if (!card.isToken() && !card.isTokenCard()) {
|
if (!card.isToken() && !card.isTokenCard()) {
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
@@ -0,0 +1,11 @@
|
|||||||
|
Name:Chishiro, the Shattered Blade
|
||||||
|
ManaCost:2 R G
|
||||||
|
Types:Legendary Creature Snake Samurai
|
||||||
|
PT:4/4
|
||||||
|
T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | TriggerZones$ Battlefield | ValidCard$ Aura.YouCtrl,Equipment.YouCtrl | Execute$ TrigToken | TriggerDescription$ Whenever an Aura or Equipment enters the battlefield under your control, create a 2/2 red Spirit creature token with menace.
|
||||||
|
SVar:TrigToken:DB$ Token | TokenScript$ r_2_2_spirit_menace
|
||||||
|
T:Mode$ Phase | Phase$ End of Turn | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigCounters | TriggerDescription$ At the beginning of your end step, put a +1/+1 counter on each modified creature you control. (Equipment, Auras you control, and counters are modifications.)
|
||||||
|
SVar:TrigCounters:DB$ PutCounterAll | ValidCards$ Creature.YouCtrl+modified | CounterType$ P1P1 | CounterNum$ 1
|
||||||
|
DeckHints:Type$Aura|Equipment & Ability$Counters
|
||||||
|
DeckHas:Ability$Token & Type$Spirit & Ability$Counters
|
||||||
|
Oracle:Whenever an Aura or Equipment enters the battlefield under your control, create a 2/2 red Spirit creature token with menace.\nAt the beginning of your end step, put a +1/+1 counter on each modified creature you control. (Equipment, Auras you control, and counters are modifications.)
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
Name:Goro-Goro, Disciple of Ryusei
|
||||||
|
ManaCost:1 R
|
||||||
|
Types:Legendary Creature Samurai Goblin
|
||||||
|
PT:2/2
|
||||||
|
A:AB$ PumpAll | Cost$ R | ValidCards$ Creature.YouCtrl | KW$ Haste | SpellDescription$ Creatures you control gain haste until end of turn.
|
||||||
|
A:AB$ Token | Cost$ 3 R R | TokenScript$ r_5_5_dragon_spirit_flying | IsPresent$ Creature.YouCtrl+attacking+modified | StackDescription$ Create a 5/5 red Dragon Spirit creature token with flying. | SpellDescription$ Create a 5/5 red Dragon Spirit creature token with flying. Activate only if you control an attacking modified creature.
|
||||||
|
DeckHas:Ability$Token & Type$Dragon|Spirit
|
||||||
|
DeckHints:Type$Equipment|Aura & Ability$Counters
|
||||||
|
Oracle:{R}: Creatures you control gain haste until end of turn.\n{3}{R}{R}: Create a 5/5 red Dragon Spirit creature token with flying. Activate only if you control an attacking modified creature.
|
||||||
7
forge-gui/res/tokenscripts/r_2_2_spirit_menace.txt
Normal file
7
forge-gui/res/tokenscripts/r_2_2_spirit_menace.txt
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
Name:Spirit Token
|
||||||
|
ManaCost:no cost
|
||||||
|
Colors:red
|
||||||
|
Types:Creature Spirit
|
||||||
|
PT:2/2
|
||||||
|
K:Menace
|
||||||
|
Oracle:Menace
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
Name:Dragon Spirit Token
|
||||||
|
ManaCost:no cost
|
||||||
|
Types:Creature Dragon Spirit
|
||||||
|
Colors:red
|
||||||
|
K:Flying
|
||||||
|
PT:5/5
|
||||||
|
Oracle:Flying
|
||||||
@@ -429,7 +429,7 @@ public final class CardScriptParser {
|
|||||||
"leastPower", "leastToughness", "greatestCMC",
|
"leastPower", "leastToughness", "greatestCMC",
|
||||||
"greatestRememberedCMC", "lowestRememberedCMC", "lowestCMC",
|
"greatestRememberedCMC", "lowestRememberedCMC", "lowestCMC",
|
||||||
"enchanted", "unenchanted", "enchanting", "equipped", "unequipped",
|
"enchanted", "unenchanted", "enchanting", "equipped", "unequipped",
|
||||||
"equipping", "token", "nonToken", "hasXCost", "suspended",
|
"equipping", "modified", "token", "nonToken", "hasXCost", "suspended",
|
||||||
"delved", "attacking", "attackingYou", "notattacking",
|
"delved", "attacking", "attackingYou", "notattacking",
|
||||||
"attackedBySourceThisCombat", "blocking", "blockingSource",
|
"attackedBySourceThisCombat", "blocking", "blockingSource",
|
||||||
"blockingCreatureYouCtrl", "blockingRemembered",
|
"blockingCreatureYouCtrl", "blockingRemembered",
|
||||||
|
|||||||
Reference in New Issue
Block a user