mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-17 11:18:01 +00:00
Investigate fixes
This commit is contained in:
@@ -37,11 +37,11 @@ public class InvestigateEffect extends TokenEffectBase {
|
||||
final int amount = AbilityUtils.calculateAmount(card, sa.getParamOrDefault("Num", "1"), sa);
|
||||
|
||||
// Investigate in Sequence
|
||||
for (final Player p : getTargetPlayers(sa)) {
|
||||
for (int i = 0; i < amount; i++) {
|
||||
for (final Player p : getTargetPlayers(sa)) {
|
||||
if (sa.hasParam("Optional") && !p.getController().confirmAction(sa, null,
|
||||
Localizer.getInstance().getMessage("lblWouldYouLikeInvestigate"), null)) {
|
||||
return;
|
||||
continue;
|
||||
}
|
||||
|
||||
CardZoneTable triggerList = new CardZoneTable();
|
||||
|
||||
@@ -169,8 +169,12 @@ public class RepeatEachEffect extends SpellAbilityEffect {
|
||||
}
|
||||
}
|
||||
for (final Player p : repeatPlayers) {
|
||||
if (optional && !p.getController().confirmAction(repeat, null, sa.getParam("RepeatOptionalMessage"), null)) {
|
||||
if (optional) {
|
||||
if (!p.getController().confirmAction(repeat, null, sa.getParam("RepeatOptionalMessage"), null)) {
|
||||
continue;
|
||||
} else if (sa.hasParam("RememberDeciders")) {
|
||||
source.addRemembered(p);
|
||||
}
|
||||
}
|
||||
if (nextTurn) {
|
||||
game.getCleanup().addUntil(p, new GameCommand() {
|
||||
|
||||
@@ -2684,14 +2684,13 @@ public class CardFactoryUtil {
|
||||
final String[] kw = keyword.split(":");
|
||||
String costStr = kw[1];
|
||||
for (SpellAbility sa: host.getBasicSpells()) {
|
||||
final SpellAbility newSA = sa.copy();
|
||||
newSA.setBasicSpell(false);
|
||||
if (costStr.equals("ConvertedManaCost")) {
|
||||
costStr = Integer.toString(host.getCMC());
|
||||
}
|
||||
final Cost cost = new Cost(costStr, false).add(sa.getPayCosts().copyWithNoMana());
|
||||
final SpellAbility newSA = sa.copyWithDefinedCost(cost);
|
||||
newSA.setBasicSpell(false);
|
||||
newSA.putParam("Secondary", "True");
|
||||
newSA.setPayCosts(cost);
|
||||
newSA.setDescription(sa.getDescription() + " (by paying " + cost.toSimpleString() + " instead of its mana cost)");
|
||||
newSA.setIntrinsic(intrinsic);
|
||||
|
||||
@@ -3879,9 +3878,8 @@ public class CardFactoryUtil {
|
||||
private static SpellAbility makeAltCostAbility(final Card card, final String altCost, final SpellAbility sa) {
|
||||
final Map<String, String> params = AbilityFactory.getMapParams(altCost);
|
||||
|
||||
final SpellAbility altCostSA = sa.copy();
|
||||
final Cost abCost = new Cost(params.get("Cost"), altCostSA.isAbility());
|
||||
altCostSA.setPayCosts(abCost);
|
||||
final Cost abCost = new Cost(params.get("Cost"), sa.isAbility());
|
||||
final SpellAbility altCostSA = sa.copyWithDefinedCost(abCost);
|
||||
altCostSA.setBasicSpell(false);
|
||||
altCostSA.addOptionalCost(OptionalCost.AltCost);
|
||||
|
||||
|
||||
@@ -4,8 +4,8 @@ Types:Legendary Creature Zombie Knight
|
||||
PT:3/3
|
||||
S:Mode$ Continuous | Affected$ Card.Self | MayPlay$ True | AffectedZone$ Graveyard | EffectZone$ Graveyard
|
||||
S:Mode$ CantBeCast | ValidCard$ Card.Self | Origin$ Exile,Hand,Library,Command | EffectZone$ Graveyard,Hand,Library,Command,Stack | Description$ You may cast CARDNAME from your graveyard, but not from anywhere else.
|
||||
S:Mode$ Continuous | Affected$ Knight.YouCtrl | MayPlay$ True | EffectZone$ Battlefield | AffectedZone$ Graveyard | Description$ As long as CARDNAME is on the battlefield, you may play Knight cards from your graveyard.
|
||||
T:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Graveyard | ValidCard$ Card.Self | Execute$ TrigLose | TriggerDescription$ When CARDNAME dies, you lose 2 life.
|
||||
S:Mode$ Continuous | Affected$ Knight.YouCtrl | ValidAfterStack$ Spell.Knight | MayPlay$ True | EffectZone$ Battlefield | AffectedZone$ Graveyard | Description$ As long as NICKNAME is on the battlefield, you may cast Knight spells from your graveyard.
|
||||
T:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Graveyard | ValidCard$ Card.Self | Execute$ TrigLose | TriggerDescription$ When NICKNAME dies, you lose 2 life.
|
||||
SVar:TrigLose:DB$ LoseLife | Defined$ You | LifeAmount$ 2
|
||||
AI:RemoveDeck:Random
|
||||
SVar:DiscardMe:5
|
||||
|
||||
@@ -2,7 +2,7 @@ Name:Malicious Affliction
|
||||
ManaCost:B B
|
||||
Types:Instant
|
||||
A:SP$ Destroy | Cost$ B B | ValidTgts$ Creature.nonBlack | TgtPrompt$ Select target nonblack creature | SpellDescription$ Destroy target nonblack creature.
|
||||
T:Mode$ SpellCast | ValidCard$ Card.Self | Execute$ TrigCopy | CheckSVar$ Morbid | SVarCompare$ GE1 | TriggerDescription$ Morbid — When you cast this spell, if a creature died this turn, you may copy CARDNAME and may choose a new target for the copy.
|
||||
T:Mode$ SpellCast | ValidCard$ Card.Self | Execute$ TrigCopy | CheckSVar$ Morbid | SVarCompare$ GE1 | OptionalDecider$ You | TriggerDescription$ Morbid — When you cast this spell, if a creature died this turn, you may copy CARDNAME and may choose a new target for the copy.
|
||||
SVar:TrigCopy:DB$ CopySpellAbility | Defined$ TriggeredSpellAbility | MayChooseTarget$ True
|
||||
SVar:Morbid:Count$ThisTurnEntered_Graveyard_from_Battlefield_Creature
|
||||
Oracle:Morbid — When you cast this spell, if a creature died this turn, you may copy Malicious Affliction and may choose a new target for the copy.\nDestroy target nonblack creature.
|
||||
|
||||
@@ -2,10 +2,10 @@ Name:Tempting Contract
|
||||
ManaCost:4
|
||||
Types:Artifact
|
||||
T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ DBRepeat | SubAbility$ DBToken | TriggerDescription$ At the beginning of your upkeep, each opponent may create a Treasure token. For each opponent who does, you create a Treasure token.
|
||||
SVar:DBRepeat:DB$ RepeatEach | RepeatSubAbility$ DBOppToken | RepeatPlayers$ Player.Opponent | SubAbility$ DBToken | RepeatOptionalForEachPlayer$ True | RepeatOptionalMessage$ Do you want to create a Treasure token?
|
||||
SVar:DBOppToken:DB$ Token | TokenScript$ c_a_treasure_sac | TokenOwner$ Player.IsRemembered | RememberTokens$ True
|
||||
SVar:DBRepeat:DB$ RepeatEach | RepeatSubAbility$ DBOppToken | RepeatPlayers$ Opponent | RepeatOptionalForEachPlayer$ True | RememberDeciders$ True | RepeatOptionalMessage$ Do you want to create a Treasure token? | ChangeZoneTable$ True | SubAbility$ DBToken
|
||||
SVar:DBOppToken:DB$ Token | TokenScript$ c_a_treasure_sac | TokenOwner$ Player.IsRemembered
|
||||
SVar:DBToken:DB$ Token | TokenAmount$ X | TokenScript$ c_a_treasure_sac | SubAbility$ DBCleanup
|
||||
SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True
|
||||
SVar:X:Remembered$Amount
|
||||
SVar:X:Count$RememberedSize
|
||||
DeckHas:Ability$Token|Sacrifice
|
||||
Oracle:At the beginning of your upkeep, each opponent may create a Treasure token. For each opponent who does, you create a Treasure token.
|
||||
|
||||
Reference in New Issue
Block a user