mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-16 18:58:00 +00:00
Clean script
This commit is contained in:
@@ -6,7 +6,7 @@ K:Protection from white
|
||||
K:Protection from black
|
||||
T:Mode$ SpellCast | ValidCard$ Creature | ValidActivatingPlayer$ You | Execute$ TrigPutCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever you cast a creature spell, put a +1/+1 counter on CARDNAME.
|
||||
SVar:TrigPutCounter:DB$ PutCounter | Defined$ Self | CounterType$ P1P1 | CounterNum$ 1
|
||||
S:Mode$ ReduceCost | ValidCard$ Creature | Type$ Spell | Activator$ You | Amount$ X | Description$ Creature spells you cast cost 1 less to cast for each +1/+1 counter on CARDNAME.
|
||||
S:Mode$ ReduceCost | ValidCard$ Creature | Type$ Spell | Activator$ You | Amount$ X | Description$ Creature spells you cast cost 1 less to cast for each +1/+1 counter on NICKNAME.
|
||||
SVar:X:Count$CardCounters.P1P1
|
||||
SVar:BuffedBy:Creature
|
||||
Oracle:Protection from white and from black\nWhenever you cast a creature spell, put a +1/+1 counter on Animar, Soul of Elements.\nCreature spells you cast cost {1} less to cast for each +1/+1 counter on Animar.
|
||||
|
||||
@@ -5,11 +5,9 @@ PT:10/10
|
||||
K:Vigilance
|
||||
K:Trample
|
||||
K:Lifelink
|
||||
R:Event$ Moved | ActiveZones$ Battlefield | Destination$ Battlefield | ValidCard$ Card.Self+wasNotCast | ReplaceWith$ Exile | Description$ If CARDNAME would enter the battlefield and it wasn't cast or no mana was spent to cast it, exile it instead.
|
||||
R:Event$ Moved | ActiveZones$ Battlefield | Destination$ Battlefield | ValidCard$ Card.Self | CheckSVar$ X | SVarCompare$ EQ0 | ReplaceWith$ Exile | Description$ If CARDNAME would enter the battlefield and it wasn't cast or no mana was spent to cast it, exile it instead.
|
||||
R:Event$ Moved | ActiveZones$ Battlefield | Destination$ Battlefield | ValidCard$ Card.Self+wasNotCast,Card.Self+CastSa Spell.ManaSpent EQ0 | ReplaceWith$ Exile | Description$ If CARDNAME would enter the battlefield and it wasn't cast or no mana was spent to cast it, exile it instead.
|
||||
SVar:Exile:DB$ ChangeZone | Hidden$ True | Origin$ All | Destination$ Exile | Defined$ ReplacedCard
|
||||
T:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Any | ValidCard$ Card.Self | Execute$ TrigExile | TriggerDescription$ When CARDNAME leaves the battlefield, exile the top ten cards of your library. You may cast any number of spells with total mana value 10 or less from among them without paying their mana costs.
|
||||
SVar:TrigExile:DB$ Dig | Defined$ You | DigNum$ 10 | ChangeNum$ All | DestinationZone$ Exile | RememberChanged$ True | SubAbility$ DBPlay
|
||||
SVar:DBPlay:DB$ Play | Valid$ Card.nonLand+IsRemembered+YouOwn+cmcLE10 | WithTotalCMC$ 10 | ValidZone$ Exile | ValidSA$ Spell | Controller$ You | WithoutManaCost$ True | Optional$ True | Amount$ All
|
||||
SVar:X:Count$CastTotalManaSpent
|
||||
Oracle:If Primeval Spawn would enter the battlefield and it wasn't cast or no mana was spent to cast it, exile it instead.\nVigilance, trample, lifelink\nWhen Primeval Spawn leaves the battlefield, exile the top ten cards of your library. You may cast any number of spells with total mana value 10 or less from among them without paying their mana costs.
|
||||
|
||||
@@ -2,11 +2,9 @@ Name:The First Tyrannic War
|
||||
ManaCost:2 G U R
|
||||
Types:Enchantment Saga
|
||||
K:Saga:3:DBChooseCard,DBDouble,DBDouble
|
||||
SVar:DBChooseCard:DB$ ChooseCard | ChoiceZone$ Hand | Choices$ Creature.YouOwn | ChoiceTitle$ You may select a creature card | Optional$ True | SubAbility$ DBEffect | SpellDescription$ You may put a creature card from your hand onto the battlefield. If its mana cost contains {X}, it enters the battlefield with a number of +1/+1 counters on it equal to the number of lands you control.
|
||||
SVar:DBEffect:DB$ Effect | ConditionDefined$ ChosenCard | ConditionPresent$ Card.hasXCost | ReplacementEffects$ ReplaceETB | RememberObjects$ ChosenCard | ExileOnMoved$ Hand | SubAbility$ DBPut
|
||||
SVar:ReplaceETB:Event$ Moved | Origin$ Hand | Destination$ Battlefield | ValidCard$ Card.ChosenCard | ReplaceWith$ PutWithCounters | Description$ If its mana cost contains {X}, it enters the battlefield with a number of +1/+1 counters on it equal to the number of lands you control.
|
||||
SVar:PutWithCounters:DB$ ChangeZone | Origin$ Hand | Destination$ Battlefield | Defined$ ChosenCard | WithCountersType$ P1P1 | WithCountersAmount$ Count$Valid Land.YouCtrl | SubAbility$ DBCleanup
|
||||
SVar:DBPut:DB$ ChangeZone | Origin$ Hand | Destination$ Battlefield | Defined$ ChosenCard | SubAbility$ DBCleanup
|
||||
SVar:DBChooseCard:DB$ ChooseCard | ChoiceZone$ Hand | Choices$ Creature.YouOwn | ChoiceTitle$ You may select a creature card | Optional$ True | SubAbility$ DBPutX | SpellDescription$ You may put a creature card from your hand onto the battlefield. If its mana cost contains {X}, it enters the battlefield with a number of +1/+1 counters on it equal to the number of lands you control.
|
||||
SVar:DBPutX:DB$ ChangeZone | Origin$ Hand | Destination$ Battlefield | Defined$ ChosenCard | WithCountersType$ P1P1 | WithCountersAmount$ Count$Valid Land.YouCtrl | ConditionDefined$ ChosenCard | ConditionPresent$ Card.hasXCost | SubAbility$ DBPut
|
||||
SVar:DBPut:DB$ ChangeZone | Origin$ Hand | Destination$ Battlefield | Defined$ ChosenCard | ConditionDefined$ ChosenCard | ConditionPresent$ Card.hasXCost | ConditionCompare$ EQ0 | SubAbility$ DBCleanup
|
||||
SVar:DBCleanup:DB$ Cleanup | ClearChosenCard$ True
|
||||
SVar:DBDouble:DB$ MultiplyCounter | ValidTgts$ Creature.YouCtrl | TgtPrompt$ Select target creature you control | Multiplier$ 2 | SpellDescription$ Double the number of each kind of counter on target creature you control.
|
||||
DeckHas:Ability$Counters
|
||||
|
||||
@@ -1030,11 +1030,8 @@ public class HumanCostDecision extends CostDecisionMakerBase {
|
||||
final String amount = cost.getAmount();
|
||||
final String type = cost.getType();
|
||||
|
||||
CardCollectionView list = CardLists.filter(player.getCardsIn(ZoneType.Battlefield), CardPredicates.canBeSacrificedBy(ability, isEffect()));
|
||||
list = CardLists.getValidCards(list, type.split(";"), player, source, ability);
|
||||
|
||||
if (cost.payCostFromSource()) {
|
||||
if (source.getController() == ability.getActivatingPlayer() && source.isInPlay()) {
|
||||
if (source.getController() == ability.getActivatingPlayer() && source.canBeSacrificedBy(ability, isEffect())) {
|
||||
return mandatory || confirmAction(cost, Localizer.getInstance().getMessage("lblSacrificeCardConfirm", CardTranslation.getTranslatedName(source.getName()))) ? PaymentDecision.card(source) : null;
|
||||
}
|
||||
return null;
|
||||
@@ -1042,12 +1039,15 @@ public class HumanCostDecision extends CostDecisionMakerBase {
|
||||
|
||||
if (type.equals("OriginalHost")) {
|
||||
Card host = ability.getOriginalHost();
|
||||
if (host.getController() == ability.getActivatingPlayer() && host.isInPlay()) {
|
||||
if (host.getController() == ability.getActivatingPlayer() && host.canBeSacrificedBy(ability, isEffect())) {
|
||||
return confirmAction(cost, Localizer.getInstance().getMessage("lblSacrificeCardConfirm", CardTranslation.getTranslatedName(host.getName()))) ? PaymentDecision.card(host) : null;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
CardCollectionView list = CardLists.filter(player.getCardsIn(ZoneType.Battlefield), CardPredicates.canBeSacrificedBy(ability, isEffect()));
|
||||
list = CardLists.getValidCards(list, type.split(";"), player, source, ability);
|
||||
|
||||
if (amount.equals("All")) {
|
||||
return PaymentDecision.card(list);
|
||||
}
|
||||
@@ -1059,6 +1059,7 @@ public class HumanCostDecision extends CostDecisionMakerBase {
|
||||
if (list.size() < c) {
|
||||
return null;
|
||||
}
|
||||
|
||||
final InputSelectCardsFromList inp = new InputSelectCardsFromList(controller, c, c, list, ability);
|
||||
inp.setMessage(Localizer.getInstance().getMessage("lblSelectATargetToSacrifice", cost.getDescriptiveType(), "%d"));
|
||||
inp.setCancelAllowed(!mandatory);
|
||||
|
||||
Reference in New Issue
Block a user