@Override public SubTypeList getSubtype(Game game) { return new SubTypeList(); }
@Override public SubTypeList getSubtype(Game game) { return new SubTypeList(); }
@Override public SubTypeList getSubtype(Game game) { return new SubTypeList(); }
public CreatureToken(int power, int toughness, String description, SubType extraSubType) { this(power, toughness, description, new SubTypeList(extraSubType)); }
@Override public SubTypeList getSubtype(Game game) { return new SubTypeList(); }
private static SubTypeList createArrayList(SubType subtype) { SubTypeList subtypes = new SubTypeList(); subtypes.add(subtype); return subtypes; }
private static SubTypeList createArrayList(SubType subtype) { SubTypeList subtypes = new SubTypeList(); subtypes.add(subtype); return subtypes; }
public EquippedHasSubtypeCondition(SubType subType){ subTypes = new SubTypeList(); subTypes.add(subType); }
public SourceHasSubtypeCondition(SubType subType){ subtypes = new SubTypeList(); subtypes.add(subType); }
public final SubTypeList getSubTypes() { SubTypeList sl = new SubTypeList(); if (subtypes.trim().isEmpty()) { return sl; } for (String s : subtypes.split(SEPARATOR)) { sl.add(SubType.fromString(s)); } return sl; }
public AbilityView(Ability ability, String sourceName, CardView sourceCard) { this.id = ability.getId(); this.name = "Ability"; this.sourceName = sourceName; this.sourceCard = sourceCard; this.rules = new ArrayList<>(); rules.add(ability.getRule()); this.power = ""; this.toughness = ""; this.loyalty = ""; this.cardTypes = EnumSet.noneOf(CardType.class); this.subTypes = new SubTypeList(); this.superTypes =EnumSet.noneOf(SuperType.class); this.color = new ObjectColor(); this.manaCost = ability.getManaCosts().getSymbols(); }
public CardAttribute(Card card, Game game) { color = card.getColor(null).copy(); subtype = new SubTypeList(); subtype.addAll(card.getSubtype(game)); }
public FendeepSummoner(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{4}{B}"); this.subtype.add(SubType.TREEFOLK); this.subtype.add(SubType.SHAMAN); this.power = new MageInt(3); this.toughness = new MageInt(5); // {T}: Up to two target Swamps each become 3/5 Treefolk Warrior creatures in addition to their other types until end of turn. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesCreatureTargetEffect( new CreatureToken(3, 5, "3/5 Treefolk Warrior", new SubTypeList(SubType.TREEFOLK, SubType.WARRIOR)), false, false, Duration.EndOfTurn), new TapSourceCost()); ability.addTarget(new TargetLandPermanent(0, 2, filter, false)); this.addAbility(ability); }
public static SubTypeList getLandTypes(boolean customSet) { SubTypeList landTypes = new SubTypeList(); for (SubType s : values()) { if (s.getSubTypeSet() == SubTypeSet.BasicLandType || s.getSubTypeSet() == SubTypeSet.NonBasicLandType) { landTypes.add(s); } } return landTypes; } }
public Hivestone(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{2}"); // Creatures you control are Slivers in addition to their other creature types. SubTypeList subTypes = new SubTypeList(); subTypes.add(SubType.SLIVER); Effect effect = new BecomesSubtypeAllEffect(Duration.WhileOnBattlefield, subTypes, filter, false); effect.setText("Creatures you control are Slivers in addition to their other creature types"); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); }
if (!getTargets().isEmpty()) { SubTypeList landTypes = new SubTypeList(); for (UUID landId : getTargets()) { Card landCard = game.getCard(landId);
public Aurification(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{2}{W}{W}"); // Whenever a creature deals damage to you, put a gold counter on it. this.addAbility(new AddGoldCountersAbility()); // Each creature with a gold counter on it is a Wall in addition to its other creature types and has defender. SubTypeList subtypes = new SubTypeList(); subtypes.add(SubType.WALL); BecomesSubtypeAllEffect becomesSubtypeAllEffect = new BecomesSubtypeAllEffect(Duration.WhileOnBattlefield, subtypes, filter, false); becomesSubtypeAllEffect.setText(""); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, becomesSubtypeAllEffect)); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(DefenderAbility.getInstance(), Duration.WhileOnBattlefield, filter, rule))); // When Aurification leaves the battlefield, remove all gold counters from all creatures. this.addAbility(new LeavesBattlefieldTriggeredAbility(new RemoveAllGoldCountersEffect(), false)); }
public EarlOfSquirrel(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{4}{G}{G}"); this.subtype.add(SubType.SQUIRREL); this.subtype.add(SubType.ADVISOR); this.power = new MageInt(4); this.toughness = new MageInt(4); // Squirrellink (Damage dealt by this creature also causes you to create that many 1/1 green Squirrel creature tokens.) this.addAbility(SquirrellinkAbility.getInstance()); // Creature tokens you control are Squirrels in addition to their other creature types. SubTypeList subTypes = new SubTypeList(); subTypes.add(SubType.SQUIRREL); Effect effect = new BecomesSubtypeAllEffect(Duration.WhileOnBattlefield, subTypes, filter, false); effect.setText("Creature tokens you control are Squirrels in addition to their other creature types"); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); // Other Squirrels you control get +1/+1. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostControlledEffect(1, 1, Duration.WhileOnBattlefield, filter2, true))); }
public JarKaiBattleStance(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{R}"); // Target creature gains double strike until end of turn. this.getSpellAbility().addEffect(new GainAbilityTargetEffect(DoubleStrikeAbility.getInstance(), Duration.EndOfTurn)); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); SubTypeList s = new SubTypeList(); s.add(SubType.JEDI); s.add(SubType.SITH); // If that creature is a Jedi or Sith, it also gains trample until end of turn. this.getSpellAbility().addEffect(new ConditionalContinuousEffect( new GainAbilityTargetEffect(TrampleAbility.getInstance(), Duration.EndOfTurn), new LockedInCondition(new SourceHasSubtypeCondition(s)), "If that creature is a Jedi or Sith, it also gains trample until end of turn")); }
public BladedBracers(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{1}"); this.subtype.add(SubType.EQUIPMENT); // Equipped creature gets +1/+1. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEquippedEffect(1, 1))); SubTypeList subTypes = new SubTypeList(); subTypes.add(SubType.HUMAN); subTypes.add(SubType.ANGEL); // As long as equipped creature is a Human or an Angel, it has vigilance. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect( new GainAbilityAttachedEffect(VigilanceAbility.getInstance(), AttachmentType.EQUIPMENT), new EquippedHasSubtypeCondition(subTypes), ruleText))); // Equip {2} this.addAbility(new EquipAbility(Outcome.BoostCreature, new GenericManaCost(2))); }