Fix Mutate + Unexpectedly Absent (#6150)

This commit is contained in:
tool4ever
2024-09-15 19:05:14 +02:00
committed by GitHub
parent 0ab14fdb37
commit cbfcbfa8c5

View File

@@ -1064,7 +1064,6 @@ public class PlayerControllerHuman extends PlayerController implements IGameCont
@Override
public CardCollectionView orderMoveToZoneList(final CardCollectionView cards, final ZoneType destinationZone, final SpellAbility source) {
boolean bottomOfLibrary = false;
if (source == null || source.getApi() != ApiType.ReorderZone) {
if (destinationZone == ZoneType.Graveyard) {
switch (FModel.getPreferences().getPref(FPref.UI_ALLOW_ORDER_GRAVEYARD_WHEN_NEEDED)) {
@@ -1087,17 +1086,14 @@ public class PlayerControllerHuman extends PlayerController implements IGameCont
}
}
if (source != null) {
if (source.hasParam("LibraryPosition")) {
bottomOfLibrary = Integer.parseInt(source.getParam("LibraryPosition")) < 0;
}
}
tempShowCards(cards);
GameEntityViewMap<Card, CardView> gameCacheMove = GameEntityView.getMap(cards);
List<CardView> choices = gameCacheMove.getTrackableKeys();
switch (destinationZone) {
case Library:
boolean bottomOfLibrary = (source != null && source.hasParam("LibraryPosition") ?
AbilityUtils.calculateAmount(source.getHostCard(), source.getParam("LibraryPosition"), source) : 0) < 0;
choices = getGui().order(localizer.getMessage("lblChooseOrderCardsPutIntoLibrary"), localizer.getMessage(bottomOfLibrary ? "lblClosestToBottom" : "lblClosestToTop"), choices, null);
break;
case Battlefield: