1
0
Fork 0
mirror of https://github.com/correl/mage.git synced 2025-04-02 03:18:09 -09:00

* Widespread Panic - Fixed that it also triggered if the library was shuffled by an ability controlled by another player (e.g. Knowledge Exploitation).

This commit is contained in:
LevelX2 2016-03-07 16:16:59 +01:00
parent f95921cc73
commit b86dd17c54
201 changed files with 340 additions and 247 deletions
Mage.Sets/src/mage/sets
alarareborn
alliances
antiquities
apocalypse
archenemy
battleforzendikar
betrayersofkamigawa
bornofthegods
championsofkamigawa
coldsnap
commander
commander2013
commander2014
commander2015
conflux
darkascension
darksteel
dissension
dragonsmaze
dragonsoftarkir
eventide
fatereforged
fifthdawn
fifthedition
futuresight
gatecrash
guildpact
innistrad
invasion
judgment
khansoftarkir
legions
limitedalpha
lorwyn
magic2010
magic2011
magic2012
magic2013
magic2015
magicorigins
mercadianmasques
mirrodin
mirrodinbesieged

View file

@ -151,7 +151,7 @@ class SovereignsOfLostAlaraEffect extends OneShotEffect {
}
}
}
you.shuffleLibrary(game);
you.shuffleLibrary(source, game);
}
return false;
}

View file

@ -140,7 +140,7 @@ class ThoughtHemorrhageEffect extends OneShotEffect {
controller.moveCardToExileWithInfo(card, null, "", source.getSourceId(), game, Zone.LIBRARY, true);
}
}
targetPlayer.shuffleLibrary(game);
targetPlayer.shuffleLibrary(source, game);
return true;
}
}

View file

@ -96,7 +96,7 @@ class WargateEffect extends OneShotEffect {
}
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return false;
}

View file

@ -87,7 +87,7 @@ class DiminishingReturnsEffect extends OneShotEffect {
for (Card card: player.getGraveyard().getCards(game)) {
card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}

View file

@ -126,10 +126,10 @@ class TransmuteArtifactEffect extends SearchEffect {
}
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return false;
}

View file

@ -121,7 +121,7 @@ class WildResearchEffect extends OneShotEffect {
}
}
controller.discardOne(true, source, game);
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -111,7 +111,7 @@ class YavimayaDryadEffect extends SearchEffect {
targetPlayer.moveCards(new CardsImpl(target.getTargets()).getCards(game),
Zone.BATTLEFIELD, source, game, true, false, false, null);
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -105,7 +105,7 @@ class BringToLightEffect extends OneShotEffect {
if (card != null) {
controller.moveCards(card, Zone.EXILED, source, game);
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
if (card != null) {
if (controller.chooseUse(outcome, "Cast " + card.getName() + " without paying its mana cost?", source, game)) {
if (card.getSpellAbility() != null) {

View file

@ -105,7 +105,7 @@ class StreamOfConsciousnessEffect extends OneShotEffect {
}
}
if (shuffle) {
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return true;
}

View file

@ -98,7 +98,7 @@ class SwayOfTheStarsEffect extends OneShotEffect {
for (Permanent permanent : game.getBattlefield().getActivePermanents(filter, controller.getId(), source.getSourceId(), game)) {
permanent.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}
return true;

View file

@ -123,10 +123,10 @@ class PeregrinationEffect extends OneShotEffect {
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return false;
}

View file

@ -97,7 +97,7 @@ class UnravelTheAEtherShuffleIntoLibraryEffect extends OneShotEffect {
Permanent permanent = game.getPermanent(targetPointer.getFirst(game, source));
if (permanent != null) {
if (permanent.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true)) {
game.getPlayer(permanent.getOwnerId()).shuffleLibrary(game);
game.getPlayer(permanent.getOwnerId()).shuffleLibrary(source, game);
return true;
}
}

View file

@ -124,7 +124,7 @@ class VortexElementalEffect extends OneShotEffect {
for (UUID playerId: playersToShuffle){
Player player = game.getPlayer(playerId);
if (player != null) {
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}

View file

@ -122,10 +122,10 @@ class GiftsUngivenEffect extends OneShotEffect {
player.moveCards(cards, Zone.LIBRARY, Zone.GRAVEYARD, source, game);
player.moveCards(cardsToKeep, Zone.LIBRARY, Zone.HAND, source, game);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return false;
}
}

View file

@ -100,7 +100,7 @@ class InameDeathAspectEffect extends SearchEffect {
if (target.getTargets().size() > 0) {
player.moveCards(new CardsImpl(target.getTargets()), Zone.LIBRARY, Zone.GRAVEYARD, source, game);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -129,7 +129,7 @@ class MindblazeEffect extends OneShotEffect {
if (player.getLibrary().count(filter, game) == count) {
player.damage(8, source.getSourceId(), game.copy(), false, true);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return false;
}

View file

@ -201,10 +201,10 @@ public class NightDealings extends CardImpl {
player.revealCards(name, cards, game);
game.informPlayers(player.getLogName() + " reveals " + card.getName());
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return false;
}
}

View file

@ -132,7 +132,7 @@ class ReweaveEffect extends OneShotEffect {
cards.remove(card);
}
library.addAll(cards.getCards(game), game);
permanentController.shuffleLibrary(game);
permanentController.shuffleLibrary(source, game);
}
}
return true;

View file

@ -125,7 +125,7 @@ class ArcumDagssonEffect extends OneShotEffect {
player.moveCards(card, Zone.BATTLEFIELD, source, game);
}
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return true;
}

View file

@ -93,7 +93,7 @@ class BuriedAliveEffect extends SearchEffect {
if (controller.searchLibrary(target, game)) {
controller.moveCards(new CardsImpl(target.getTargets()), Zone.LIBRARY, Zone.GRAVEYARD, source, game);
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -111,7 +111,7 @@ class CollectiveVoyageEffect extends OneShotEffect {
}
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}

View file

@ -125,10 +125,10 @@ class KodamasReachEffect extends OneShotEffect {
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return false;
}

View file

@ -106,7 +106,7 @@ class TrenchGorgerEffect extends OneShotEffect {
controller.moveCardToExileWithInfo(card, null, "", source.getSourceId(), game, Zone.LIBRARY, true);
count++;
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
game.addEffect(new SetPowerToughnessSourceEffect(count, count, Duration.EndOfGame, SubLayer.SetPT_7b), source);
return true;
}

View file

@ -106,7 +106,7 @@ class VeteranExplorerEffect extends OneShotEffect {
}
}
for (Player player: usingPlayers) {
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return true;
}

View file

@ -126,7 +126,7 @@ class FromTheAshesEffect extends OneShotEffect {
}
}
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}

View file

@ -108,7 +108,7 @@ class LimDulsVaultEffect extends OneShotEffect {
if (doAgain) {
player.loseLife(1, game);
} else {
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
TargetCard target = new TargetCard(Zone.LIBRARY, new FilterCard(doAgain ? textBottom : textTop));

View file

@ -134,7 +134,7 @@ class TemptWithDiscoveryEffect extends OneShotEffect {
for (UUID playerId : playersShuffle) {
Player player = game.getPlayer(playerId);
if (player != null) {
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}
return true;

View file

@ -55,7 +55,6 @@ public class WidespreadPanic extends CardImpl {
super(ownerId, 131, "Widespread Panic", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{R}");
this.expansionSetCode = "C13";
// Whenever a spell or ability causes its controller to shuffle his or her library, that player puts a card from his or her hand on top of his or her library.
this.addAbility(new WidespreadPanicTriggeredAbility());
}
@ -92,10 +91,13 @@ class WidespreadPanicTriggeredAbility extends TriggeredAbilityImpl {
@Override
public boolean checkTrigger(GameEvent event, Game game) {
for (Effect effect :this.getEffects()) {
effect.setTargetPointer(new FixedTarget(event.getPlayerId()));
if (event.getPlayerId().equals(game.getControllerId(event.getSourceId()))) {
for (Effect effect : this.getEffects()) {
effect.setTargetPointer(new FixedTarget(event.getPlayerId()));
}
return true;
}
return true;
return false;
}
@Override

View file

@ -138,7 +138,7 @@ class WaveOfVitriolEffect extends OneShotEffect {
}
controller.moveCards(toBattlefield.getCards(game), Zone.BATTLEFIELD, source, game, true, false, true, null);
for (Player player : playersToShuffle) {
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return true;

View file

@ -123,7 +123,7 @@ class OreskosExplorerEffect extends OneShotEffect {
controller.moveCards(cards.getCards(game), Zone.HAND, source, game);
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
}

View file

@ -150,7 +150,7 @@ class SyntheticDestinyDelayedEffect extends OneShotEffect {
controller.revealCards(sourceObject.getIdName(), revealed, game);
controller.moveCards(creatureCards, Zone.BATTLEFIELD, source, game, false, false, true, null);
controller.putCardsOnTopOfLibrary(nonCreatureCards, game, source, false);
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -173,7 +173,7 @@ class ConfluxEffect extends OneShotEffect {
for (Card card : cards.getCards(game)) {
card.moveToZone(Zone.HAND, source.getSourceId(), game, true);
}
you.shuffleLibrary(game);
you.shuffleLibrary(source, game);
}
return true;
}

View file

@ -101,7 +101,7 @@ class PathToExileEffect extends OneShotEffect {
player.moveCards(card, Zone.BATTLEFIELD, source, game, true, false, false, null);
}
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return true;
}

View file

@ -95,7 +95,7 @@ class ShardConvergenceEffect extends OneShotEffect {
searchLand(player, source, game, cards, "Mountain");
player.revealCards("Shard Convergence", cards, game);
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}

View file

@ -87,7 +87,7 @@ class ArchangelsLightEffect extends OneShotEffect {
for (Card card: controller.getGraveyard().getCards(game)) {
controller.moveCardToLibraryWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD, true, true);
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -119,11 +119,11 @@ class CurseOfMisfortunesEffect extends OneShotEffect {
if (card != null) {
this.setTargetPointer(new FixedTarget(targetPlayer.getId()));
game.getState().setValue("attachTo:" + card.getId(), targetPlayer.getId());
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return card.putOntoBattlefield(game, Zone.LIBRARY, source.getSourceId(), source.getControllerId());
}
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}
return false;

View file

@ -114,7 +114,7 @@ class IncreasingAmbitionEffect extends SearchEffect {
}
}
// shuffle anyway
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
}

View file

@ -109,10 +109,10 @@ class ReshapeSearchEffect extends OneShotEffect {
controller.moveCards(card, Zone.BATTLEFIELD, source, game);
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return false;
}

View file

@ -122,7 +122,7 @@ class SeekEffect extends OneShotEffect {
}
}
}
opponent.shuffleLibrary(game);
opponent.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -102,7 +102,7 @@ class LoamingShamanEffect extends OneShotEffect {
card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
}
}
targetPlayer.shuffleLibrary(game);
targetPlayer.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -99,7 +99,7 @@ class ProteanHulkEffect extends OneShotEffect {
if (controller != null) {
Cards cardsPicked = this.ProteanHulkSearch(game, source);
controller.moveCards(cardsPicked.getCards(game), Zone.BATTLEFIELD, source, game);
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -140,7 +140,7 @@ class ResearchEffect extends OneShotEffect {
game.informPlayers(player.getLogName() + " has chosen " + count + " card(s) to shuffle into his or her library.");
if (count > 0) {
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return true;

View file

@ -168,7 +168,7 @@ class ReapIntellectEffect extends OneShotEffect {
}
targetPlayer.shuffleLibrary(game);
targetPlayer.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -92,7 +92,7 @@ class LearnFromThePastEffect extends OneShotEffect {
for (Card card: player.getGraveyard().getCards(game)) {
player.moveCardToLibraryWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD, true, true);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -115,7 +115,7 @@ class EndlessHorizonsEffect extends SearchEffect {
}
}
}
you.shuffleLibrary(game);
you.shuffleLibrary(source, game);
return true;
}

View file

@ -122,7 +122,7 @@ class NightmareIncursionEffect extends OneShotEffect {
}
}
if (targetPlayer != null) {
targetPlayer.shuffleLibrary(game);
targetPlayer.shuffleLibrary(source, game);
}
return result;
}

View file

@ -153,7 +153,7 @@ class RenownedWeaponsmithEffect extends OneShotEffect {
controller.moveCards(revealed, null, Zone.HAND, source, game);
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -69,7 +69,7 @@ class AcquireEffect extends OneShotEffect {
if (targetCard != null) {
controller.moveCards(targetCard, Zone.BATTLEFIELD, source, game);
}
opponent.shuffleLibrary(game);
opponent.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -104,7 +104,7 @@ class JestersCapEffect extends OneShotEffect {
applied |= player.moveCardToExileWithInfo(targetCard, null, null, source.getSourceId(), game, Zone.LIBRARY, true);
}
}
targetPlayer.shuffleLibrary(game);
targetPlayer.shuffleLibrary(source, game);
}
return applied;
}

View file

@ -123,7 +123,7 @@ class PortentEffect extends OneShotEffect {
card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
}
if (you.chooseUse(Outcome.Neutral, "You may have that player shuffle his or her library", source, game)){
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return true;
}

View file

@ -90,7 +90,7 @@ class WindsOfChangeEffect extends OneShotEffect {
if (player != null) {
permanentsCount.put(playerId, player.getHand().size());
player.moveCards(player.getHand(), Zone.HAND, Zone.LIBRARY, source, game);
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}
for (UUID playerId : game.getState().getPlayersInRange(source.getControllerId(), game)) {

View file

@ -99,7 +99,7 @@ class BitterOrdealEffect extends OneShotEffect {
controller.moveCardToExileWithInfo(card, null, null, source.getSourceId(), game, Zone.LIBRARY, true);
}
}
targetPlayer.shuffleLibrary(game);
targetPlayer.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -106,10 +106,10 @@ class SereneRemembranceEffect extends OneShotEffect {
result |= card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, false);
Player player = game.getPlayer(card.getOwnerId());
if (player != null){
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
if (graveyardPlayer != null && !graveyardPlayer.equals(player)) {
graveyardPlayer.shuffleLibrary(game);
graveyardPlayer.shuffleLibrary(source, game);
}
return result;
}

View file

@ -118,10 +118,10 @@ class SignalTheClansEffect extends SearchEffect {
card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
}
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return false;
}

View file

@ -111,7 +111,7 @@ class UnexpectedResultEffect extends OneShotEffect {
return false;
}
if (controller.getLibrary().size() > 0) {
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
Card card = controller.getLibrary().getFromTop(game);
if (card == null) {
return false;

View file

@ -28,11 +28,7 @@
package mage.sets.guildpact;
import java.util.UUID;
import mage.constants.CardType;
import mage.constants.Rarity;
import mage.MageInt;
import mage.ObjectColor;
import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
import mage.abilities.common.SimpleActivatedAbility;
@ -42,6 +38,8 @@ import mage.abilities.effects.common.CreateTokenEffect;
import mage.abilities.effects.common.RegenerateSourceEffect;
import mage.abilities.keyword.FlyingAbility;
import mage.cards.CardImpl;
import mage.constants.CardType;
import mage.constants.Rarity;
import mage.constants.Zone;
import mage.filter.common.FilterControlledCreaturePermanent;
import mage.filter.predicate.mageobject.SubtypePredicate;

View file

@ -111,10 +111,10 @@ class BitterheartWitchEffect extends OneShotEffect {
card.putOntoBattlefield(game, Zone.LIBRARY, source.getSourceId(), source.getControllerId());
targetPlayer.addAttachment(card.getId(), game);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return false;
}

View file

@ -106,7 +106,7 @@ class CaravanVigilEffect extends OneShotEffect {
controller.revealCards(sourceObject.getIdName(), cards, game);
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -184,7 +184,7 @@ class GarrukTheVeilCursedEffect extends OneShotEffect {
controller.revealCards("Garruk, the Veil-Cursed", cards, game);
}
// shuffle
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -107,7 +107,7 @@ class GhostQuarterEffect extends OneShotEffect {
controller.moveCards(card, Zone.BATTLEFIELD, source, game);
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
}
return true;
}

View file

@ -108,7 +108,7 @@ class MemorysJourneyEffect extends OneShotEffect {
}
}
if (shuffle) {
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return true;
}

View file

@ -94,7 +94,7 @@ class MirrorMadPhantasmEffect extends OneShotEffect {
Player player = game.getPlayer(perm.getOwnerId());
if (player != null) {
perm.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
Cards cards = new CardsImpl();
while (true) {
Card card = player.getLibrary().removeFromTop(game);

View file

@ -107,7 +107,7 @@ class ThicketElementalEffect extends OneShotEffect {
}
controller.revealCards(sourceObject.getIdName(), revealedCards, game);
controller.moveCards(revealedCards, Zone.LIBRARY, source, game);
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -108,7 +108,7 @@ class KrosanReclamationEffect extends OneShotEffect {
}
}
if (shuffle) {
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return true;
}

View file

@ -109,10 +109,10 @@ class SearchLibraryPutInGraveEffect extends SearchEffect {
player.revealCards("Quiet Speculation", cards, game);
player.moveCards(cards, Zone.LIBRARY, Zone.GRAVEYARD, source, game);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return false;
}

View file

@ -96,7 +96,7 @@ class CranialArchiveEffect extends OneShotEffect {
for (Card card: targetPlayer.getGraveyard().getCards(game)){
targetPlayer.moveCardToLibraryWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD, true, true);
}
targetPlayer.shuffleLibrary(game);
targetPlayer.shuffleLibrary(source, game);
}
controller.drawCards(1, game);
return true;

View file

@ -128,7 +128,7 @@ class DarkSupplicantEffect extends OneShotEffect {
}
}
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
// Graveyard check
if (player.chooseUse(Outcome.Benefit, "Do you want to search your graveyard for Scion of Darkness?", source, game)) {

View file

@ -113,7 +113,7 @@ class ElvishSoultillerEffect extends OneShotEffect {
filter.add(new SubtypePredicate(typeChoice.getChoice()));
cardsToLibrary.addAll(controller.getGraveyard().getCards(filter, source.getSourceId(), source.getControllerId(), game));
controller.putCardsOnTopOfLibrary(cardsToLibrary, game, source, false);
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -120,7 +120,7 @@ class NaturalSelectionEffect extends OneShotEffect {
card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
}
if (you.chooseUse(Outcome.Neutral, "You may have that player shuffle his or her library", source, game)){
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
return true;
}

View file

@ -86,7 +86,7 @@ class TimetwisterEffect extends OneShotEffect {
if (player != null) {
player.moveCards(player.getHand(), Zone.HAND, Zone.LIBRARY, source, game);
player.moveCards(player.getGraveyard(), Zone.GRAVEYARD, Zone.LIBRARY, source, game);
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}
return true;

View file

@ -124,7 +124,7 @@ class PrimalCommandShuffleGraveyardEffect extends OneShotEffect {
for (Card card: player.getGraveyard().getCards(game)) {
player.moveCardToLibraryWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD, true, true);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -107,7 +107,7 @@ class HauntingEchoesEffect extends OneShotEffect {
}
}
}
targetPlayer.shuffleLibrary(game);
targetPlayer.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -130,7 +130,7 @@ class SphinxAmbassadorEffect extends OneShotEffect {
}
}
targetPlayer.shuffleLibrary(game);
targetPlayer.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -117,7 +117,7 @@ class WarpWorldEffect extends OneShotEffect {
}
if (count > 0) {
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
permanentsCount.put(playerId, count);
}

View file

@ -126,10 +126,10 @@ class CultivateEffect extends OneShotEffect {
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return false;
}

View file

@ -92,7 +92,7 @@ class ElixerOfImmortalityEffect extends OneShotEffect {
for (Card card: player.getGraveyard().getCards(game)) {
player.moveCardToLibraryWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD, true, true);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -113,7 +113,7 @@ class HoardingDragonEffect extends OneShotEffect {
}
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -112,7 +112,7 @@ class MassPolymorphEffect extends OneShotEffect {
controller.revealCards(sourceObject.getIdName(), revealed, game);
controller.moveCards(creatureCards, Zone.BATTLEFIELD, source, game, false, false, true, null);
controller.putCardsOnTopOfLibrary(nonCreatureCards, game, source, false);
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -88,7 +88,7 @@ class TimeReversalEffect extends OneShotEffect {
if (player != null) {
player.moveCards(player.getHand(), Zone.HAND, Zone.LIBRARY, source, game);
player.moveCards(player.getGraveyard(), Zone.GRAVEYARD, Zone.LIBRARY, source, game);
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}
return true;

View file

@ -140,7 +140,7 @@ class ArachnusSpinnerEffect extends OneShotEffect {
zone = Zone.LIBRARY;
}
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
if (card != null) {
Permanent permanent = game.getPermanent(source.getFirstTarget());

View file

@ -123,7 +123,7 @@ class DoublingChantEffect extends OneShotEffect {
for (Card card : chosenCards) {
card.putOntoBattlefield(game, Zone.LIBRARY, source.getSourceId(), source.getControllerId());
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
}

View file

@ -99,7 +99,7 @@ class BoundlessRealmsEffect extends OneShotEffect {
if (controller.searchLibrary(target, game)) {
controller.moveCards(new CardsImpl(target.getTargets()).getCards(game), Zone.BATTLEFIELD, source, game, true, false, false, null);
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
}

View file

@ -103,7 +103,7 @@ class DiabolicRevelationEffect extends OneShotEffect {
}
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return true;
}
}

View file

@ -106,7 +106,7 @@ class GemOfBecomingEffect extends OneShotEffect {
searchLand(player, source, game, cards, "Mountain");
player.revealCards("Gem of Becoming", cards, game);
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return false;
}

View file

@ -157,7 +157,7 @@ class ShimianSpecterEffect extends OneShotEffect {
controller.moveCardToExileWithInfo(card, null, "", source.getSourceId(), game, Zone.LIBRARY, true);
}
}
targetPlayer.shuffleLibrary(game);
targetPlayer.shuffleLibrary(source, game);
}
return true;
}

View file

@ -94,13 +94,13 @@ class VoidStalkerEffect extends OneShotEffect {
p.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
Player pl = game.getPlayer(p.getControllerId());
if (pl != null)
pl.shuffleLibrary(game);
pl.shuffleLibrary(source, game);
}
if (s != null) {
s.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
Player pl = game.getPlayer(s.getControllerId());
if (pl != null)
pl.shuffleLibrary(game);
pl.shuffleLibrary(source, game);
}
return true;
}

View file

@ -134,7 +134,7 @@ class BoonweaverGiantEffect extends OneShotEffect {
zone = Zone.LIBRARY;
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
}
// aura card found - attach it
if (card != null) {

View file

@ -141,7 +141,7 @@ class GenesisHydraPutOntoBattlefieldEffect extends OneShotEffect {
game.informPlayers("No nonland permanent card with converted mana cost " + count + " or less to choose.");
}
controller.moveCards(cards, Zone.LIBRARY, source, game);
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}

View file

@ -119,7 +119,7 @@ class JaceTheLivingGuildpactEffect extends OneShotEffect {
for (Card card : player.getGraveyard().getCards(game)) {
card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}
controller.drawCards(7, game);

View file

@ -145,7 +145,7 @@ class NissaWorldwakerSearchEffect extends OneShotEffect {
}
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
}

View file

@ -114,7 +114,7 @@ class YisanTheWandererBardEffect extends OneShotEffect {
Card card = controller.getLibrary().getCard(target.getFirstTarget(), game);
controller.moveCards(card, Zone.BATTLEFIELD, source, game);
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -90,7 +90,7 @@ class DaysUndoingEffect extends OneShotEffect {
if (player != null) {
player.moveCards(player.getHand(), Zone.HAND, Zone.LIBRARY, source, game);
player.moveCards(player.getGraveyard(), Zone.GRAVEYARD, Zone.LIBRARY, source, game);
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}

View file

@ -118,7 +118,7 @@ class NissasPilgrimageEffect extends OneShotEffect {
}
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -120,7 +120,7 @@ class TheGreatAuroraEffect extends OneShotEffect {
for (Permanent permanent : list) {
player.moveCardToLibraryWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD, true, true);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}

View file

@ -105,10 +105,10 @@ class WoodlandBellowerEffect extends OneShotEffect {
Card card = controller.getLibrary().getCard(target.getFirstTarget(), game);
controller.moveCards(card, Zone.BATTLEFIELD, source, game);
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return false;
}

View file

@ -93,7 +93,7 @@ class BriberyEffect extends OneShotEffect {
Card card = opponent.getLibrary().getCard(target.getFirstTarget(), game);
controller.moveCards(card, Zone.BATTLEFIELD, source, game);
}
opponent.shuffleLibrary(game);
opponent.shuffleLibrary(source, game);
return true;
}
return false;

View file

@ -83,7 +83,7 @@ class PsychogenicProbeTriggeredAbility extends TriggeredAbilityImpl {
public boolean checkEventType(GameEvent event, Game game) {
return event.getType().equals(EventType.LIBRARY_SHUFFLED);
}
@java.lang.Override
public boolean checkTrigger(GameEvent event, Game game) {
for (Effect effect : this.getEffects()) {
@ -94,6 +94,6 @@ class PsychogenicProbeTriggeredAbility extends TriggeredAbilityImpl {
@java.lang.Override
public String getRule() {
return "Whenever a spell or ability causes a player to shuffle his or her library, Psychogenic Probe deals 2 damage to him or her.";
return "Whenever a spell or ability causes a player to shuffle his or her library, {this} deals 2 damage to him or her.";
}
}

View file

@ -96,7 +96,7 @@ class TemporalCascadeShuffleEffect extends OneShotEffect {
for (Card card: player.getGraveyard().getCards(game)) {
card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
}
}

View file

@ -93,7 +93,7 @@ class DistantMemoriesEffect extends OneShotEffect {
Card card = player.getLibrary().remove(target.getFirstTarget(), game);
if (card != null) {
card.moveToZone(Zone.EXILED, source.getSourceId(), game, false);
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
StringBuilder sb = new StringBuilder();
sb.append("Have ").append(player.getLogName()).append(" put ").append(card.getName());
@ -117,7 +117,7 @@ class DistantMemoriesEffect extends OneShotEffect {
return true;
}
}
player.shuffleLibrary(game);
player.shuffleLibrary(source, game);
return false;
}
}

View file

@ -105,10 +105,10 @@ class GreenSunsZenithSearchEffect extends OneShotEffect {
controller.moveCards(card, Zone.BATTLEFIELD, source, game);
}
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return true;
}
controller.shuffleLibrary(game);
controller.shuffleLibrary(source, game);
return false;
}

Some files were not shown because too many files have changed in this diff Show more