forked from External/mage
* Add minimum and maximum target counts as parameters for TargetAmount and its subclasses; update/add several rules comments (and one actual text) for clarity; remove unused imports * Get amount+description from target instead of parameters for DistributeCountersEffect and DamageMultiEffect; additions to TargetImpl.getDescription to accommodate * Create separate method to check if "any number" phrasing should be used, override it in TargetAmount * Check instanceof TargetAmount before casting * Add new constructors to chain off of for TargetCreaturePermanentAmount & TargetCreatureOrPlaneswalkerAmount * Fix text for Storm the Seedcore * Use Integer.MAX_VALUE instead of 0 to represent no maximum targets * Add comment about getUseAnyNumber() * Use amount-only constructors in some TargetAmount subclasses, add clarifying documentation * Fix a few calls * Require more specific filters
52 lines
2 KiB
Java
52 lines
2 KiB
Java
package mage.cards.f;
|
|
|
|
import mage.abilities.condition.common.KickedCondition;
|
|
import mage.abilities.decorator.ConditionalOneShotEffect;
|
|
import mage.abilities.effects.common.DamageMultiEffect;
|
|
import mage.abilities.effects.common.DamageTargetEffect;
|
|
import mage.abilities.keyword.KickerAbility;
|
|
import mage.cards.CardImpl;
|
|
import mage.cards.CardSetInfo;
|
|
import mage.constants.CardType;
|
|
import mage.target.common.TargetAnyTarget;
|
|
import mage.target.common.TargetAnyTargetAmount;
|
|
import mage.target.common.TargetCreaturePermanent;
|
|
import mage.target.targetadjustment.ConditionalTargetAdjuster;
|
|
|
|
import java.util.UUID;
|
|
|
|
/**
|
|
*
|
|
* @author TheElk801
|
|
*/
|
|
public final class FightWithFire extends CardImpl {
|
|
|
|
public FightWithFire(UUID ownerId, CardSetInfo setInfo) {
|
|
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{2}{R}");
|
|
|
|
// Kicker {5}{R}
|
|
this.addAbility(new KickerAbility("{5}{R}"));
|
|
|
|
// Fight with Fire deals 5 damage to target creature. If this spell was kicked, it deals 10 damage divided as you choose among any number of targets instead.<i> (Those targets can include players and planeswalkers.)</i>
|
|
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
|
|
new DamageMultiEffect(),
|
|
new DamageTargetEffect(5),
|
|
KickedCondition.ONCE,
|
|
"{this} deals 5 damage to target creature. If this spell was kicked, "
|
|
+ "it deals 10 damage divided as you choose among any number of targets instead."
|
|
+ "<i> (Those targets can include players and planeswalkers.)</i>"
|
|
));
|
|
this.getSpellAbility().addTarget(new TargetAnyTarget());
|
|
this.getSpellAbility().setTargetAdjuster(new ConditionalTargetAdjuster(KickedCondition.ONCE,
|
|
new TargetCreaturePermanent(), new TargetAnyTargetAmount(10)));
|
|
}
|
|
|
|
private FightWithFire(final FightWithFire card) {
|
|
super(card);
|
|
}
|
|
|
|
@Override
|
|
public FightWithFire copy() {
|
|
return new FightWithFire(this);
|
|
}
|
|
}
|