- ChangeZoneAll will now actually use player targets (this fixes Reminisce and some other card that target players).

This commit is contained in:
jendave
2011-08-06 21:27:51 +00:00
parent b0d27ca81b
commit e5c03c83e9

View File

@@ -1413,9 +1413,17 @@ public class AbilityFactory_ChangeZone {
HashMap<String,String> params = af.getMapParams();
String destination = params.get("Destination");
String origin = params.get("Origin");
CardList cards = AllZoneUtil.getCardsInZone(origin);
cards = filterListByType(cards, params, "ChangeType", sa);
Player tgtPlayer = null;
if(af.getAbTgt().getTargetPlayers() != null) {
tgtPlayer = af.getAbTgt().getTargetPlayers().get(0);
cards = AllZoneUtil.getCardsInZone(origin,tgtPlayer);
}
// I don't know if library position is necessary. It's here if it is, just in case
int libraryPos = params.containsKey("LibraryPosition") ? Integer.parseInt(params.get("LibraryPosition")) : 0;
for(Card c : cards){