mirror of
https://github.com/magefree/mage.git
synced 2026-01-26 05:09:16 -08:00
Some minor changes to framework and existing cards.
This commit is contained in:
parent
def8db4119
commit
eae5b7c61e
4 changed files with 50 additions and 16 deletions
|
|
@ -41,6 +41,7 @@ import mage.constants.Zone;
|
|||
import mage.filter.common.FilterCreatureCard;
|
||||
import mage.game.Game;
|
||||
import mage.players.Player;
|
||||
import mage.target.Target;
|
||||
import mage.target.common.TargetCardInYourGraveyard;
|
||||
|
||||
/**
|
||||
|
|
@ -60,7 +61,9 @@ public class PhyrexianDelver extends CardImpl<PhyrexianDelver> {
|
|||
|
||||
// When Phyrexian Delver enters the battlefield, return target creature card from your graveyard to the battlefield. You lose life equal to that card's converted mana cost.
|
||||
Ability ability = new EntersBattlefieldTriggeredAbility(new PhyrexianDelverEffect(), false);
|
||||
ability.addTarget(new TargetCardInYourGraveyard(1, new FilterCreatureCard()));
|
||||
Target target = new TargetCardInYourGraveyard(1, new FilterCreatureCard("creature card from your graveyard"));
|
||||
target.setRequired(true);
|
||||
ability.addTarget(target);
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
|
|
@ -95,7 +98,10 @@ class PhyrexianDelverEffect extends OneShotEffect<PhyrexianDelverEffect> {
|
|||
Card creatureCard = game.getCard(this.getTargetPointer().getFirst(game, source));
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
if (creatureCard != null && controller != null) {
|
||||
boolean result = creatureCard.putOntoBattlefield(game, Zone.GRAVEYARD, source.getSourceId(), source.getControllerId());
|
||||
boolean result = false;
|
||||
if (game.getState().getZone(creatureCard.getId()).equals(Zone.GRAVEYARD)) {
|
||||
result = controller.putOntoBattlefieldWithInfo(creatureCard, game, Zone.GRAVEYARD, source.getSourceId());
|
||||
}
|
||||
controller.loseLife(creatureCard.getManaCost().convertedManaCost(), game);
|
||||
return result;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ public class RitesOfReaping extends CardImpl<RitesOfReaping> {
|
|||
|
||||
// Target creature gets +3/+3 until end of turn. Another target creature gets -3/-3 until end of turn.
|
||||
this.getSpellAbility().addEffect(new RitesOfReapingEffect());
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanent(2));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanent(2, true));
|
||||
}
|
||||
|
||||
public RitesOfReaping(final RitesOfReaping card) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue