From ed4584cbe8d0f24e61b49cd6165e0dab9f941cb6 Mon Sep 17 00:00:00 2001 From: magenoxx Date: Mon, 7 Mar 2011 18:12:54 +0300 Subject: [PATCH] Fixed damage sourceId in various places. --- Mage.Sets/src/mage/sets/magic2010/Earthquake.java | 2 +- .../src/mage/sets/mirrodinbesieged/BurntheImpure.java | 2 +- Mage.Sets/src/mage/sets/scarsofmirrodin/ArcTrail.java | 4 ++-- Mage.Sets/src/mage/sets/scarsofmirrodin/Embersmith.java | 2 +- .../src/mage/sets/scarsofmirrodin/SpikeshotElder.java | 2 +- .../src/mage/sets/shardsofalara/FlameblastDragon.java | 2 +- Mage.Sets/src/mage/sets/worldwake/SearingBlaze.java | 8 ++++---- .../mage/abilities/effects/common/DamageTargetEffect.java | 4 ++-- 8 files changed, 13 insertions(+), 13 deletions(-) diff --git a/Mage.Sets/src/mage/sets/magic2010/Earthquake.java b/Mage.Sets/src/mage/sets/magic2010/Earthquake.java index e361e1a1a0..ab3e52f259 100644 --- a/Mage.Sets/src/mage/sets/magic2010/Earthquake.java +++ b/Mage.Sets/src/mage/sets/magic2010/Earthquake.java @@ -101,7 +101,7 @@ class EarthquakeEffect extends OneShotEffect { for (UUID playerId: game.getPlayer(source.getControllerId()).getInRange()) { Player player = game.getPlayer(playerId); if (player != null) - player.damage(amount, source.getId(), game, false, true); + player.damage(amount, source.getSourceId(), game, false, true); } return true; } diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/BurntheImpure.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/BurntheImpure.java index 21af921610..8637b6d2e9 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/BurntheImpure.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/BurntheImpure.java @@ -98,7 +98,7 @@ public class BurntheImpure extends CardImpl { if (permanent.getAbilities().contains(InfectAbility.getInstance())) { Player controller = game.getPlayer(permanent.getControllerId()); if (controller != null) { - controller.damage(amount, source.getId(), game, true, false); + controller.damage(amount, source.getSourceId(), game, true, false); } } return true; diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/ArcTrail.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/ArcTrail.java index 269260334e..6789d6cd7f 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/ArcTrail.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/ArcTrail.java @@ -102,11 +102,11 @@ class ArcTrailEffect extends OneShotEffect { } if (permanent != null) { - applied |= (permanent.damage( damage, source.getId(), game, false, true ) > 0); + applied |= (permanent.damage( damage, source.getSourceId(), game, false, true ) > 0); } Player player = game.getPlayer(target); if (player != null) { - applied |= (player.damage( damage, source.getId(), game, false, true ) > 0); + applied |= (player.damage( damage, source.getSourceId(), game, false, true ) > 0); } twoDamageDone = true; diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/Embersmith.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/Embersmith.java index f58df6e894..7992cade83 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/Embersmith.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/Embersmith.java @@ -129,7 +129,7 @@ class EmbersmithEffect extends OneShotEffect { } Player player = game.getPlayer(source.getFirstTarget()); if (player != null) { - player.damage(1, source.getId(), game, false, true); + player.damage(1, source.getSourceId(), game, false, true); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/SpikeshotElder.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/SpikeshotElder.java index f37f28af46..9dd1edbe94 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/SpikeshotElder.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/SpikeshotElder.java @@ -94,7 +94,7 @@ class SpikeshotElderEffect extends OneShotEffect { } Player player = game.getPlayer(source.getFirstTarget()); if (sourcePermanent != null && player != null) { - player.damage(sourcePermanent.getPower().getValue(), source.getId(), game, false, true); + player.damage(sourcePermanent.getPower().getValue(), source.getSourceId(), game, false, true); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/shardsofalara/FlameblastDragon.java b/Mage.Sets/src/mage/sets/shardsofalara/FlameblastDragon.java index ee7a87a0d5..9cf04afcc7 100644 --- a/Mage.Sets/src/mage/sets/shardsofalara/FlameblastDragon.java +++ b/Mage.Sets/src/mage/sets/shardsofalara/FlameblastDragon.java @@ -100,7 +100,7 @@ class FlameblastDragonEffect extends OneShotEffect { } Player targetPlayer = game.getPlayer(source.getFirstTarget()); if (targetPlayer != null) { - targetPlayer.damage(costX, source.getId(), game, true, false); + targetPlayer.damage(costX, source.getSourceId(), game, true, false); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/worldwake/SearingBlaze.java b/Mage.Sets/src/mage/sets/worldwake/SearingBlaze.java index c355254f92..9a324ae57b 100644 --- a/Mage.Sets/src/mage/sets/worldwake/SearingBlaze.java +++ b/Mage.Sets/src/mage/sets/worldwake/SearingBlaze.java @@ -129,18 +129,18 @@ class SearingBlazeEffect extends OneShotEffect { Permanent creature = game.getPermanent(source.getTargets().get(1).getFirstTarget()); if (watcher != null && watcher.conditionMet()) { if (player != null) { - player.damage(3, source.getId(), game, false, true); + player.damage(3, source.getSourceId(), game, false, true); } if (creature != null) { - creature.damage(3, source.getId(), game, true, false); + creature.damage(3, source.getSourceId(), game, true, false); } } else { if (player != null) { - player.damage(1, source.getId(), game, false, true); + player.damage(1, source.getSourceId(), game, false, true); } if (creature != null) { - creature.damage(1, source.getId(), game, true, false); + creature.damage(1, source.getSourceId(), game, true, false); } } return true; diff --git a/Mage/src/mage/abilities/effects/common/DamageTargetEffect.java b/Mage/src/mage/abilities/effects/common/DamageTargetEffect.java index 3de36a3865..524502d0c5 100644 --- a/Mage/src/mage/abilities/effects/common/DamageTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/DamageTargetEffect.java @@ -73,12 +73,12 @@ public class DamageTargetEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Permanent permanent = game.getPermanent(source.getFirstTarget()); if (permanent != null) { - permanent.damage(amount, source.getId(), game, preventable, false); + permanent.damage(amount, source.getSourceId(), game, preventable, false); return true; } Player player = game.getPlayer(source.getFirstTarget()); if (player != null) { - player.damage(amount, source.getId(), game, false, preventable); + player.damage(amount, source.getSourceId(), game, false, preventable); return true; } return false;