From 00c0b4191b9eec5098debebede98acb02fa7f72b Mon Sep 17 00:00:00 2001 From: LevelX2 Date: Sun, 20 Apr 2014 23:43:14 +0200 Subject: [PATCH] * Oppressive Rays - Fixed that the attacking costs haven't to be payed from the owner of the enchanted creature. --- .../sets/journeyintonyx/OppressiveRays.java | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/Mage.Sets/src/mage/sets/journeyintonyx/OppressiveRays.java b/Mage.Sets/src/mage/sets/journeyintonyx/OppressiveRays.java index 3eadfd4090..6d5d23eac3 100644 --- a/Mage.Sets/src/mage/sets/journeyintonyx/OppressiveRays.java +++ b/Mage.Sets/src/mage/sets/journeyintonyx/OppressiveRays.java @@ -75,7 +75,7 @@ public class OppressiveRays extends CardImpl { // Enchanted creature can't attack or block unless its controller pays 3. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new OppressiveRaysEffect())); // Activated abilities of enchanted creature cost {3} more to activate. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new OppressiveRaysCostReductionEffect() )); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new OppressiveRaysCostModificationEffect() )); } public OppressiveRays(final OppressiveRays card) { @@ -125,8 +125,8 @@ class OppressiveRaysEffect extends ReplacementEffectImpl { @Override public boolean applies(GameEvent event, Ability source, Game game) { - if ( event.getType() == GameEvent.EventType.DECLARE_ATTACKER) { - Permanent attacker = game.getPermanent(event.getTargetId()); + if (event.getType().equals(GameEvent.EventType.DECLARE_ATTACKER)) { + Permanent attacker = game.getPermanent(event.getSourceId()); return attacker != null && attacker.getAttachments().contains(source.getSourceId()); } return false; @@ -139,20 +139,20 @@ class OppressiveRaysEffect extends ReplacementEffectImpl { } -class OppressiveRaysCostReductionEffect extends CostModificationEffectImpl { +class OppressiveRaysCostModificationEffect extends CostModificationEffectImpl { - OppressiveRaysCostReductionEffect ( ) { + OppressiveRaysCostModificationEffect ( ) { super(Duration.WhileOnBattlefield, Outcome.Benefit, CostModificationType.INCREASE_COST); staticText = "Activated abilities of enchanted creature cost {3} more to activate"; } - OppressiveRaysCostReductionEffect(OppressiveRaysCostReductionEffect effect) { + OppressiveRaysCostModificationEffect(OppressiveRaysCostModificationEffect effect) { super(effect); } @Override public boolean apply(Game game, Ability source, Ability abilityToModify) { - CardUtil.increaseCost(abilityToModify, 2); + CardUtil.increaseCost(abilityToModify, 3); return true; } @@ -169,8 +169,8 @@ class OppressiveRaysCostReductionEffect extends CostModificationEffectImpl