Fix Wheel of Potential (#5983)

* Wheel of Potential revision

* Logic cleanup

---------

Co-authored-by: tool4EvEr <tool4EvEr@192.168.0.60>
This commit is contained in:
tool4ever
2024-08-24 11:25:36 +00:00
committed by GitHub
parent 6a503ccdbd
commit 30a358dda1
9 changed files with 26 additions and 42 deletions

View File

@@ -2,7 +2,6 @@ package forge.game;
import java.util.Collection;
import java.util.HashMap;
import java.util.List;
import java.util.Map.Entry;
import com.google.common.collect.Iterables;
@@ -93,11 +92,7 @@ public class GameLogFormatter extends IGameEventVisitor.Base<GameLogEntry> {
if (event.sa.getTargetRestrictions() != null) {
StringBuilder sb = new StringBuilder();
List<TargetChoices> targets = event.sa.getAllTargetChoices();
// Include the TargetChoices from the stack instance, since the real target choices
// are on that object at this point (see SpellAbilityStackInstance constructor).
targets.add(event.si.getTargetChoices());
for (TargetChoices ch : targets) {
for (TargetChoices ch : event.sa.getAllTargetChoices()) {
if (null != ch) {
sb.append(ch);
}

View File

@@ -5524,6 +5524,8 @@ public class Card extends GameEntity implements Comparable<Card>, IHasSVars {
return isInstant() || isSorcery() || (isAura() && !isInZone(ZoneType.Battlefield));
}
public final boolean hasPlayableLandFace() { return isLand() || (isModal() && getState(CardStateName.Modal).getType().isLand()); }
public final boolean isLand() { return getType().isLand(); }
public final boolean isBasicLand() { return getType().isBasicLand(); }
public final boolean isSnow() { return getType().isSnow(); }

View File

@@ -22,7 +22,6 @@ import java.util.Comparator;
import com.google.common.base.Predicate;
import com.google.common.collect.Iterables;
import forge.card.CardStateName;
import forge.game.CardTraitBase;
import forge.game.GameEntity;
import forge.game.combat.CombatUtil;
@@ -379,7 +378,7 @@ public final class CardPredicates {
/**
* a Predicate<Card> to get all lands.
*/
public static final Predicate<Card> LANDS = c -> c.isLand() || (!c.isInZone(ZoneType.Battlefield) && c.isModal() && c.getState(CardStateName.Modal).getType().isLand());
public static final Predicate<Card> LANDS = c -> c.isLand();
/**
* a Predicate<Card> to get all mana-producing lands.
*/