mirror of
https://github.com/correl/mage.git
synced 2025-03-29 17:00:07 -09:00
* Liliana's Careess - Fixed target handling of opponent.
This commit is contained in:
parent
d989131980
commit
213f8e7071
3 changed files with 15 additions and 6 deletions
Mage.Sets/src/mage/sets/magic2011
Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords
Utils/release
|
@ -29,16 +29,17 @@
|
|||
package mage.sets.magic2011;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.TriggeredAbilityImpl;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.LoseLifeTargetEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Rarity;
|
||||
import mage.constants.Zone;
|
||||
import mage.abilities.TriggeredAbilityImpl;
|
||||
import mage.abilities.effects.common.LoseLifeTargetEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.GameEvent;
|
||||
import mage.game.events.GameEvent.EventType;
|
||||
import mage.target.TargetPlayer;
|
||||
import mage.target.targetpointer.FixedTarget;
|
||||
|
||||
/**
|
||||
*
|
||||
|
@ -50,6 +51,8 @@ public class LilianasCaress extends CardImpl {
|
|||
super(ownerId, 103, "Liliana's Caress", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}");
|
||||
this.expansionSetCode = "M11";
|
||||
this.color.setBlack(true);
|
||||
|
||||
// Whenever an opponent discards a card, that player loses 2 life.
|
||||
this.addAbility(new LilianasCaressAbility());
|
||||
}
|
||||
|
||||
|
@ -82,8 +85,9 @@ class LilianasCaressAbility extends TriggeredAbilityImpl {
|
|||
@Override
|
||||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
if (event.getType() == EventType.DISCARDED_CARD && game.getOpponents(controllerId).contains(event.getPlayerId())) {
|
||||
this.addTarget(new TargetPlayer());
|
||||
getTargets().get(0).add(event.getPlayerId(), game);
|
||||
for (Effect effect :this.getEffects()) {
|
||||
effect.setTargetPointer(new FixedTarget(event.getPlayerId()));
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
|
|
@ -92,6 +92,9 @@ public class PersistTest extends CardTestPlayerBase {
|
|||
|
||||
|
||||
/**
|
||||
* see here for more information
|
||||
* http://www.slightlymagic.net/forum/viewtopic.php?f=116&t=14516
|
||||
*
|
||||
* Tests Safehold Elite with persist returns to battlefield with -1/-1 counter
|
||||
* Murder Investigation puts 2 tokens onto battlefield because enchanted Safehold Elite
|
||||
* was 2/2
|
||||
|
|
|
@ -39,6 +39,8 @@ since 1.3.0-2014-06-15
|
|||
git log 6c8b818d890e9e0ce4bc5e3128249bb9e62c0b23..HEAD --diff-filter=A --name-status | sed -ne "s/^A[^u]Mage.Sets\/src\/mage\/sets\///p" | sort > added_cards.txt
|
||||
since 1.3.0-2014-06-28
|
||||
git log 1129858a6c5c0dae5d1e29ea931804c1165b8c38..HEAD --diff-filter=A --name-status | sed -ne "s/^A[^u]Mage.Sets\/src\/mage\/sets\///p" | sort > added_cards.txt
|
||||
since 1.3.0-2014-07-11
|
||||
git log 458255cd0627af90c2ebeab4c410a16d55a36f41..HEAD --diff-filter=A --name-status | sed -ne "s/^A[^u]Mage.Sets\/src\/mage\/sets\///p" | sort > added_cards.txt
|
||||
|
||||
|
||||
3. Copy added_cards.txt to trunk\Utils folder
|
||||
|
|
Loading…
Add table
Reference in a new issue