mirror of
https://github.com/correl/mage.git
synced 2024-11-24 19:19:56 +00:00
[AFR] Implemented Ray of Enfeeblement
This commit is contained in:
parent
f17b8e4b86
commit
cee3db672a
3 changed files with 70 additions and 1 deletions
68
Mage.Sets/src/mage/cards/r/RayOfEnfeeblement.java
Normal file
68
Mage.Sets/src/mage/cards/r/RayOfEnfeeblement.java
Normal file
|
@ -0,0 +1,68 @@
|
||||||
|
package mage.cards.r;
|
||||||
|
|
||||||
|
import mage.abilities.Ability;
|
||||||
|
import mage.abilities.effects.OneShotEffect;
|
||||||
|
import mage.abilities.effects.common.continuous.BoostTargetEffect;
|
||||||
|
import mage.cards.CardImpl;
|
||||||
|
import mage.cards.CardSetInfo;
|
||||||
|
import mage.constants.CardType;
|
||||||
|
import mage.constants.Duration;
|
||||||
|
import mage.constants.Outcome;
|
||||||
|
import mage.game.Game;
|
||||||
|
import mage.game.permanent.Permanent;
|
||||||
|
import mage.target.common.TargetCreaturePermanent;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author TheElk801
|
||||||
|
*/
|
||||||
|
public final class RayOfEnfeeblement extends CardImpl {
|
||||||
|
|
||||||
|
public RayOfEnfeeblement(UUID ownerId, CardSetInfo setInfo) {
|
||||||
|
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{B}");
|
||||||
|
|
||||||
|
// Target creature gets -4/-1 until end of turn. If that creature is white, it gets -4/-4 until end of turn instead.
|
||||||
|
this.getSpellAbility().addEffect(new RayOfEnfeeblementEffect());
|
||||||
|
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||||
|
}
|
||||||
|
|
||||||
|
private RayOfEnfeeblement(final RayOfEnfeeblement card) {
|
||||||
|
super(card);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public RayOfEnfeeblement copy() {
|
||||||
|
return new RayOfEnfeeblement(this);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
class RayOfEnfeeblementEffect extends OneShotEffect {
|
||||||
|
|
||||||
|
RayOfEnfeeblementEffect() {
|
||||||
|
super(Outcome.Benefit);
|
||||||
|
staticText = "target creature gets -4/-1 until end of turn. " +
|
||||||
|
"If that creature is white, it gets -4/-4 until end of turn instead";
|
||||||
|
}
|
||||||
|
|
||||||
|
private RayOfEnfeeblementEffect(final RayOfEnfeeblementEffect effect) {
|
||||||
|
super(effect);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public RayOfEnfeeblementEffect copy() {
|
||||||
|
return new RayOfEnfeeblementEffect(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean apply(Game game, Ability source) {
|
||||||
|
Permanent permanent = game.getPermanent(source.getFirstTarget());
|
||||||
|
if (permanent == null) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
game.addEffect(new BoostTargetEffect(
|
||||||
|
-4, permanent.getColor(game).isWhite() ? -4 : -1, Duration.EndOfTurn
|
||||||
|
), source);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
|
@ -133,6 +133,7 @@ public final class AdventuresInTheForgottenRealms extends ExpansionSet {
|
||||||
cards.add(new SetCardInfo("Prosperous Innkeeper", 200, Rarity.UNCOMMON, mage.cards.p.ProsperousInnkeeper.class));
|
cards.add(new SetCardInfo("Prosperous Innkeeper", 200, Rarity.UNCOMMON, mage.cards.p.ProsperousInnkeeper.class));
|
||||||
cards.add(new SetCardInfo("Purple Worm", 201, Rarity.UNCOMMON, mage.cards.p.PurpleWorm.class));
|
cards.add(new SetCardInfo("Purple Worm", 201, Rarity.UNCOMMON, mage.cards.p.PurpleWorm.class));
|
||||||
cards.add(new SetCardInfo("Ranger's Hawk", 37, Rarity.COMMON, mage.cards.r.RangersHawk.class));
|
cards.add(new SetCardInfo("Ranger's Hawk", 37, Rarity.COMMON, mage.cards.r.RangersHawk.class));
|
||||||
|
cards.add(new SetCardInfo("Ray of Enfeeblement", 116, Rarity.UNCOMMON, mage.cards.r.RayOfEnfeeblement.class));
|
||||||
cards.add(new SetCardInfo("Red Dragon", 160, Rarity.UNCOMMON, mage.cards.r.RedDragon.class));
|
cards.add(new SetCardInfo("Red Dragon", 160, Rarity.UNCOMMON, mage.cards.r.RedDragon.class));
|
||||||
cards.add(new SetCardInfo("Rimeshield Frost Giant", 69, Rarity.COMMON, mage.cards.r.RimeshieldFrostGiant.class));
|
cards.add(new SetCardInfo("Rimeshield Frost Giant", 69, Rarity.COMMON, mage.cards.r.RimeshieldFrostGiant.class));
|
||||||
cards.add(new SetCardInfo("Rust Monster", 161, Rarity.UNCOMMON, mage.cards.r.RustMonster.class));
|
cards.add(new SetCardInfo("Rust Monster", 161, Rarity.UNCOMMON, mage.cards.r.RustMonster.class));
|
||||||
|
|
|
@ -41419,7 +41419,7 @@ Lolth, Spider Queen|Adventures in the Forgotten Realms|112|M|{3}{B}{B}|Legendary
|
||||||
Manticore|Adventures in the Forgotten Realms|113|C|{3}{B}|Creature - Manticore|2|1|Flash$Flying$Tail Spikes — When Manticore enters the battlefield, destroy target creature an opponent controls that was dealt damage this turn.|
|
Manticore|Adventures in the Forgotten Realms|113|C|{3}{B}|Creature - Manticore|2|1|Flash$Flying$Tail Spikes — When Manticore enters the battlefield, destroy target creature an opponent controls that was dealt damage this turn.|
|
||||||
Power Word Kill|Adventures in the Forgotten Realms|114|U|{1}{B}|Instant|||Destroy target non-Angel, non-Demon, non-Devil, non-Dragon creature.|
|
Power Word Kill|Adventures in the Forgotten Realms|114|U|{1}{B}|Instant|||Destroy target non-Angel, non-Demon, non-Devil, non-Dragon creature.|
|
||||||
Precipitous Drop|Adventures in the Forgotten Realms|115|C|{2}{B}|Enchantment - Aura|||Enchant creature$When Precipitous Drop enters the battlefield, venture into the dungeon.$Enchanted creature gets -2/-2. It gets -5/-5 instead as long as you've completed a dungeon.|
|
Precipitous Drop|Adventures in the Forgotten Realms|115|C|{2}{B}|Enchantment - Aura|||Enchant creature$When Precipitous Drop enters the battlefield, venture into the dungeon.$Enchanted creature gets -2/-2. It gets -5/-5 instead as long as you've completed a dungeon.|
|
||||||
Ray of Enfeeblement|Adventures in the Forgotten Realms|116|U|{W}|Instant|||Target creature gets -4/-1 until end of turn. If that creature is white, it gets -4/-4 until end of turn instead.|
|
Ray of Enfeeblement|Adventures in the Forgotten Realms|116|U|{B}|Instant|||Target creature gets -4/-1 until end of turn. If that creature is white, it gets -4/-4 until end of turn instead.|
|
||||||
Sepulcher Ghoul|Adventures in the Forgotten Realms|118|C|{1}{B}|Creature - Zombie|2|1|Sacrifice another creature: Sepulcher Ghoul gets +2/+2 until end of turn. Activate only once each turn.|
|
Sepulcher Ghoul|Adventures in the Forgotten Realms|118|C|{1}{B}|Creature - Zombie|2|1|Sacrifice another creature: Sepulcher Ghoul gets +2/+2 until end of turn. Activate only once each turn.|
|
||||||
Shambling Ghast|Adventures in the Forgotten Realms|119|C|{B}|Creature - Zombie|1|1|When Shambling Ghast dies, choose one —$• Brave the Stench — Target creature an opponent controls -1/-1 until end of turn.$• Search the Body — Create a Treasure token.|
|
Shambling Ghast|Adventures in the Forgotten Realms|119|C|{B}|Creature - Zombie|1|1|When Shambling Ghast dies, choose one —$• Brave the Stench — Target creature an opponent controls -1/-1 until end of turn.$• Search the Body — Create a Treasure token.|
|
||||||
Skullport Merchant|Adventures in the Forgotten Realms|120|U|{2}{B}|Creature - Dwarf Citizen|1|4|When Skullport Merchant enters the battlefield, create a Treasure token.${1}{B}, Sacrifice another creature or a Treasure: Draw a card.|
|
Skullport Merchant|Adventures in the Forgotten Realms|120|U|{2}{B}|Creature - Dwarf Citizen|1|4|When Skullport Merchant enters the battlefield, create a Treasure token.${1}{B}, Sacrifice another creature or a Treasure: Draw a card.|
|
||||||
|
|
Loading…
Reference in a new issue