Skip to content

Commit

Permalink
Rule text changes - Oracle updates 11.01.2018 (closes #4412)
Browse files Browse the repository at this point in the history
  • Loading branch information
LevelX2 committed Jan 14, 2018
1 parent 0f13ac8 commit 07ab5cb
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 18 deletions.
25 changes: 13 additions & 12 deletions Mage.Sets/src/mage/cards/c/CalmingVerse.java
Expand Up @@ -51,13 +51,13 @@
* @author escplan9 (Derek Monturo - dmontur1 at gmail dot com)
*/
public class CalmingVerse extends CardImpl {

public CalmingVerse(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{3}{G}");
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{G}");

// Destroy all enchantments you don't control. Then, if you control an untapped land, destroy all enchantments you control.
this.getSpellAbility().addEffect(new CalmingVerseEffect());

}

public CalmingVerse(final CalmingVerse card) {
Expand All @@ -71,24 +71,25 @@ public CalmingVerse copy() {
}

class CalmingVerseEffect extends OneShotEffect {

private static final FilterPermanent untappedLandFilter = new FilterPermanent("If you control an untapped land");

static {
untappedLandFilter.add(new CardTypePredicate(CardType.LAND));
untappedLandFilter.add(Predicates.not(new TappedPredicate()));
}

private static final FilterEnchantmentPermanent opponentEnchantmentsFilter = new FilterEnchantmentPermanent("enchantments you don't control");

static {
opponentEnchantmentsFilter.add(new ControllerPredicate(TargetController.OPPONENT));
}

private static final FilterControlledEnchantmentPermanent controlledEnchantmentsFilter = new FilterControlledEnchantmentPermanent("enchantments you control");

private static final FilterControlledEnchantmentPermanent controlledEnchantmentsFilter = new FilterControlledEnchantmentPermanent("enchantments you control");

public CalmingVerseEffect() {
super(Outcome.Detriment);
this.staticText = "Destroy all enchantments you don't control. Then, if you control an untapped land, destroy all enchantments you control";
this.staticText = "Destroy all enchantments you don't control. Then if you control an untapped land, destroy all enchantments you control";
}

public CalmingVerseEffect(final CalmingVerseEffect effect) {
Expand All @@ -106,17 +107,17 @@ public boolean apply(Game game, Ability source) {
for (Permanent permanent : game.getBattlefield().getActivePermanents(opponentEnchantmentsFilter, source.getControllerId(), source.getSourceId(), game)) {
permanent.destroy(source.getSourceId(), game, false);
}

// Then if you control an untapped land, destroy all own enchantments
Player controller = game.getPlayer(source.getControllerId());
if (controller != null) {
if (game.getState().getBattlefield().countAll(untappedLandFilter, controller.getId(), game) > 0) {

if (game.getState().getBattlefield().countAll(untappedLandFilter, controller.getId(), game) > 0) {
for (Permanent permanent : game.getBattlefield().getActivePermanents(controlledEnchantmentsFilter, source.getControllerId(), source.getSourceId(), game)) {
permanent.destroy(source.getSourceId(), game, false);
}
}

}
return true;
}
Expand Down
7 changes: 3 additions & 4 deletions Mage.Sets/src/mage/cards/g/GrafdiggersCage.java
Expand Up @@ -50,7 +50,7 @@
public class GrafdiggersCage extends CardImpl {

public GrafdiggersCage(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{1}");
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{1}");

// Creature cards can't enter the battlefield from graveyards or libraries.
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GrafdiggersCageEffect()));
Expand All @@ -73,7 +73,7 @@ class GrafdiggersCageEffect extends ContinuousRuleModifyingEffectImpl {

public GrafdiggersCageEffect() {
super(Duration.WhileOnBattlefield, Outcome.Benefit);
staticText = "Creature cards can't enter the battlefield from graveyards or libraries";
staticText = "Creature cards in graveyards and libraries can't enter the battlefield";
}

public GrafdiggersCageEffect(final GrafdiggersCageEffect effect) {
Expand Down Expand Up @@ -120,12 +120,11 @@ public GrafdiggersCageEffect2 copy() {
return new GrafdiggersCageEffect2(this);
}


@Override
public boolean checksEventType(GameEvent event, Game game) {
return event.getType() == GameEvent.EventType.CAST_SPELL;
}

@Override
public boolean applies(GameEvent event, Ability source, Game game) {
Card card = game.getCard(event.getSourceId());
Expand Down
4 changes: 2 additions & 2 deletions Mage.Sets/src/mage/cards/r/RhysticScrying.java
Expand Up @@ -48,7 +48,7 @@
public class RhysticScrying extends CardImpl {

public RhysticScrying(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{2}{U}{U}");
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{2}{U}{U}");

// Draw three cards. Then, if any player pays {2}, discard three cards.
this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(3));
Expand All @@ -69,7 +69,7 @@ class RhysticScryingEffect extends OneShotEffect {

public RhysticScryingEffect() {
super(Outcome.Benefit);
this.staticText = "Then, if any player pays {2}, discard three cards";
this.staticText = "Then if any player pays {2}, discard three cards";
}

public RhysticScryingEffect(final RhysticScryingEffect effect) {
Expand Down

0 comments on commit 07ab5cb

Please sign in to comment.