[FIN] Implement Fire Magic

This commit is contained in:
theelk801 2025-05-11 14:57:43 -04:00
parent 9cff375406
commit 6e124806db
6 changed files with 86 additions and 5 deletions

View file

@ -0,0 +1,47 @@
package mage.cards.f;
import mage.abilities.Mode;
import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.DamageAllEffect;
import mage.abilities.keyword.TieredAbility;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.filter.StaticFilters;
import java.util.UUID;
/**
* @author TheElk801
*/
public final class FireMagic extends CardImpl {
public FireMagic(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{R}");
// Tiered
this.addAbility(new TieredAbility(this));
// * Fire -- {0} -- Fire Magic deals 1 damage to each creature.
this.getSpellAbility().addEffect(new DamageAllEffect(1, StaticFilters.FILTER_PERMANENT_CREATURE));
this.getSpellAbility().withFirstModeCost(new GenericManaCost(1));
this.getSpellAbility().withFirstModeFlavorWord("Fire");
// * Fira -- {2} -- Fire Magic deals 2 damage to each creature.
this.getSpellAbility().addMode(new Mode(new DamageAllEffect(2, StaticFilters.FILTER_PERMANENT_CREATURE))
.withCost(new GenericManaCost(2)).withFlavorWord("Fira"));
// * Firaga -- {5} -- Fire Magic deals 3 damage to each creature.
this.getSpellAbility().addMode(new Mode(new DamageAllEffect(3, StaticFilters.FILTER_PERMANENT_CREATURE))
.withCost(new GenericManaCost(5)).withFlavorWord("Firaga"));
}
private FireMagic(final FireMagic card) {
super(card);
}
@Override
public FireMagic copy() {
return new FireMagic(this);
}
}

View file

@ -61,6 +61,7 @@ public final class FinalFantasy extends ExpansionSet {
cards.add(new SetCardInfo("Fang, Fearless l'Cie", 446, Rarity.UNCOMMON, mage.cards.f.FangFearlessLCie.class, NON_FULL_USE_VARIOUS)); cards.add(new SetCardInfo("Fang, Fearless l'Cie", 446, Rarity.UNCOMMON, mage.cards.f.FangFearlessLCie.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Fang, Fearless l'Cie", 526, Rarity.UNCOMMON, mage.cards.f.FangFearlessLCie.class, NON_FULL_USE_VARIOUS)); cards.add(new SetCardInfo("Fang, Fearless l'Cie", 526, Rarity.UNCOMMON, mage.cards.f.FangFearlessLCie.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Fang, Fearless l'Cie", 99, Rarity.UNCOMMON, mage.cards.f.FangFearlessLCie.class, NON_FULL_USE_VARIOUS)); cards.add(new SetCardInfo("Fang, Fearless l'Cie", 99, Rarity.UNCOMMON, mage.cards.f.FangFearlessLCie.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Fire Magic", 136, Rarity.UNCOMMON, mage.cards.f.FireMagic.class));
cards.add(new SetCardInfo("Forest", 306, Rarity.LAND, mage.cards.basiclands.Forest.class, FULL_ART_BFZ_VARIOUS)); cards.add(new SetCardInfo("Forest", 306, Rarity.LAND, mage.cards.basiclands.Forest.class, FULL_ART_BFZ_VARIOUS));
cards.add(new SetCardInfo("Forest", 307, Rarity.LAND, mage.cards.basiclands.Forest.class, FULL_ART_BFZ_VARIOUS)); cards.add(new SetCardInfo("Forest", 307, Rarity.LAND, mage.cards.basiclands.Forest.class, FULL_ART_BFZ_VARIOUS));
cards.add(new SetCardInfo("Forest", 308, Rarity.LAND, mage.cards.basiclands.Forest.class, FULL_ART_BFZ_VARIOUS)); cards.add(new SetCardInfo("Forest", 308, Rarity.LAND, mage.cards.basiclands.Forest.class, FULL_ART_BFZ_VARIOUS));

View file

@ -617,11 +617,9 @@ public class Modes extends LinkedHashMap<UUID, Mode> implements Copyable<Modes>
sb.append("<br>"); sb.append("<br>");
for (Mode mode : this.values()) { for (Mode mode : this.values()) {
if (mode.getCost() != null) { if (mode.getCost() != null && mode.getFlavorWord() == null) {
// for Spree // for Spree
sb.append("+ "); sb.append("+ ");
sb.append(mode.getCost().getText());
sb.append(" &mdash; ");
} else if (mode.getPawPrintValue() > 0) { } else if (mode.getPawPrintValue() > 0) {
for (int i = 0; i < mode.getPawPrintValue(); ++i) { for (int i = 0; i < mode.getPawPrintValue(); ++i) {
sb.append("{P}"); sb.append("{P}");

View file

@ -115,10 +115,18 @@ public class Effects extends ArrayList<Effect> {
sbText.append('.'); sbText.append('.');
} }
if (mode.getCost() != null || mode.getFlavorWord() != null) {
sbText.replace(0, 1, sbText.substring(0, 1).toUpperCase());
}
// cost
if (mode.getCost() != null) {
sbText.insert(0, " &mdash; ");
sbText.insert(0, mode.getCost().getText());
}
// flavor word // flavor word
if (mode.getFlavorWord() != null) { if (mode.getFlavorWord() != null) {
return CardUtil.italicizeWithEmDash(mode.getFlavorWord()) sbText.insert(0, CardUtil.italicizeWithEmDash(mode.getFlavorWord()));
+ CardUtil.getTextWithFirstCharUpperCase(sbText.toString());
} }
return sbText.toString(); return sbText.toString();

View file

@ -0,0 +1,26 @@
package mage.abilities.keyword;
import mage.abilities.StaticAbility;
import mage.cards.Card;
import mage.constants.Zone;
/**
* @author TheElk801
*/
public class TieredAbility extends StaticAbility {
public TieredAbility(Card card) {
super(Zone.ALL, null);
this.setRuleVisible(false);
card.getSpellAbility().getModes().setChooseText("Tiered <i>(Choose one additional cost.)</i>");
}
private TieredAbility(final TieredAbility ability) {
super(ability);
}
@Override
public TieredAbility copy() {
return new TieredAbility(this);
}
}

View file

@ -134,6 +134,7 @@ Suspend|number, cost, card|
Swampcycling|cost| Swampcycling|cost|
Swampwalk|new| Swampwalk|new|
Umbra armor|new| Umbra armor|new|
Tiered|card|
Toxic|number| Toxic|number|
Training|new| Training|new|
Trample|instance| Trample|instance|