mirror of
https://github.com/magefree/mage.git
synced 2025-12-21 02:52:02 -08:00
Changeling - improved combo support for creature type triggers and changeling spells (example: Volo, Itinerant Scholar) (#11569)
This commit is contained in:
parent
3bc9999207
commit
1737a0a9eb
2 changed files with 7 additions and 5 deletions
|
|
@ -13,7 +13,7 @@ import mage.game.permanent.Permanent;
|
||||||
import mage.game.stack.Spell;
|
import mage.game.stack.Spell;
|
||||||
import mage.players.Player;
|
import mage.players.Player;
|
||||||
|
|
||||||
import java.util.HashSet;
|
import java.util.LinkedHashSet;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
|
@ -32,7 +32,7 @@ public final class VolosJournalToken extends TokenImpl {
|
||||||
).addHint(VolosJournalTokenHint.instance));
|
).addHint(VolosJournalTokenHint.instance));
|
||||||
}
|
}
|
||||||
|
|
||||||
protected VolosJournalToken(final VolosJournalToken token) {
|
private VolosJournalToken(final VolosJournalToken token) {
|
||||||
super(token);
|
super(token);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -42,13 +42,13 @@ public final class VolosJournalToken extends TokenImpl {
|
||||||
|
|
||||||
public static Set<String> getNotedTypes(Game game, Permanent permanent) {
|
public static Set<String> getNotedTypes(Game game, Permanent permanent) {
|
||||||
if (permanent == null) {
|
if (permanent == null) {
|
||||||
return new HashSet<>();
|
return new LinkedHashSet<>();
|
||||||
}
|
}
|
||||||
|
|
||||||
String key = "notedTypes_" + permanent.getId() + '_' + permanent.getZoneChangeCounter(game);
|
String key = "notedTypes_" + permanent.getId() + '_' + permanent.getZoneChangeCounter(game);
|
||||||
Object value = game.getState().getValue(key);
|
Object value = game.getState().getValue(key);
|
||||||
if (value == null) {
|
if (value == null) {
|
||||||
Set<String> types = new HashSet<>();
|
Set<String> types = new LinkedHashSet<>();
|
||||||
game.getState().setValue(key, types);
|
game.getState().setValue(key, types);
|
||||||
return types;
|
return types;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1129,15 +1129,17 @@ public class Spell extends StackObjectImpl implements Card {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isAllCreatureTypes(Game game) {
|
public boolean isAllCreatureTypes(Game game) {
|
||||||
return false;
|
return card.isAllCreatureTypes(game);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setIsAllCreatureTypes(boolean value) {
|
public void setIsAllCreatureTypes(boolean value) {
|
||||||
|
card.setIsAllCreatureTypes(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setIsAllCreatureTypes(Game game, boolean value) {
|
public void setIsAllCreatureTypes(Game game, boolean value) {
|
||||||
|
card.setIsAllCreatureTypes(game, value);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue