mirror of
https://github.com/magefree/mage.git
synced 2025-12-26 13:32:06 -08:00
[AFR] added tokens and images download support;
This commit is contained in:
parent
88484f5a1e
commit
654ee7791c
20 changed files with 125 additions and 34 deletions
|
|
@ -7,6 +7,8 @@ import mage.constants.CardType;
|
|||
import mage.constants.SubType;
|
||||
import mage.constants.SuperType;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
|
|
@ -20,8 +22,11 @@ public final class BooToken extends TokenImpl {
|
|||
subtype.add(SubType.HAMSTER);
|
||||
power = new MageInt(1);
|
||||
toughness = new MageInt(1);
|
||||
|
||||
addAbility(TrampleAbility.getInstance());
|
||||
addAbility(HasteAbility.getInstance());
|
||||
|
||||
availableImageSetCodes = Arrays.asList("AFR");
|
||||
}
|
||||
|
||||
private BooToken(final BooToken token) {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
|
||||
package mage.game.permanent.token;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
|
||||
import mage.MageInt;
|
||||
|
|
@ -27,11 +28,15 @@ public final class DevilToken extends TokenImpl {
|
|||
color.setRed(true);
|
||||
power = new MageInt(1);
|
||||
toughness = new MageInt(1);
|
||||
|
||||
// When this creature dies, it deals 1 damage to any target.
|
||||
Effect effect = new DamageTargetEffect(1);
|
||||
effect.setText("it deals 1 damage to any target");
|
||||
Ability ability = new DiesSourceTriggeredAbility(effect);
|
||||
ability.addTarget(new TargetAnyTarget());
|
||||
this.addAbility(ability);
|
||||
|
||||
availableImageSetCodes = Arrays.asList("SOI", "WAR", "AFR");
|
||||
}
|
||||
|
||||
public DevilToken(final DevilToken token) {
|
||||
|
|
|
|||
|
|
@ -13,6 +13,8 @@ import mage.constants.Zone;
|
|||
import mage.game.Game;
|
||||
import mage.players.Player;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author weirddan455
|
||||
|
|
@ -27,10 +29,14 @@ public final class DogIllusionToken extends TokenImpl {
|
|||
subtype.add(SubType.ILLUSION);
|
||||
power = new MageInt(0);
|
||||
toughness = new MageInt(0);
|
||||
addAbility(new SimpleStaticAbility(Zone.ALL, new SetPowerToughnessSourceEffect(
|
||||
|
||||
// This creature's power and toughness are each equal to twice the number of cards in your hand.
|
||||
this.addAbility(new SimpleStaticAbility(Zone.ALL, new SetPowerToughnessSourceEffect(
|
||||
DogIllusionValue.instance, Duration.EndOfGame)
|
||||
.setText("this creature's power and toughness are each equal to twice the number of cards in your hand")
|
||||
));
|
||||
|
||||
availableImageSetCodes = Arrays.asList("AFR");
|
||||
}
|
||||
|
||||
private DogIllusionToken(final DogIllusionToken token) {
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ public final class GoblinToken extends TokenImpl {
|
|||
|
||||
availableImageSetCodes = Arrays.asList("10E", "ALA", "SOM", "M10", "NPH", "M13", "RTR",
|
||||
"MMA", "M15", "C14", "KTK", "EVG", "DTK", "ORI", "DDG", "DDN", "EVG", "MM2",
|
||||
"MM3", "EMA", "C16", "DOM", "ANA", "RNA", "WAR", "MH1", "TSR", "MH2");
|
||||
"MM3", "EMA", "C16", "DOM", "ANA", "RNA", "WAR", "MH1", "TSR", "MH2", "AFR");
|
||||
}
|
||||
|
||||
public GoblinToken(final GoblinToken token) {
|
||||
|
|
|
|||
|
|
@ -6,6 +6,8 @@ import mage.constants.CardType;
|
|||
import mage.constants.SubType;
|
||||
import mage.constants.SuperType;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
|
|
@ -19,7 +21,11 @@ public final class GuenhwyvarToken extends TokenImpl {
|
|||
subtype.add(SubType.CAT);
|
||||
power = new MageInt(4);
|
||||
toughness = new MageInt(1);
|
||||
addAbility(TrampleAbility.getInstance());
|
||||
|
||||
// Trample
|
||||
this.addAbility(TrampleAbility.getInstance());
|
||||
|
||||
availableImageSetCodes = Arrays.asList("AFR");
|
||||
}
|
||||
|
||||
private GuenhwyvarToken(final GuenhwyvarToken token) {
|
||||
|
|
|
|||
|
|
@ -14,6 +14,8 @@ import mage.filter.common.FilterCreaturePermanent;
|
|||
import mage.filter.predicate.permanent.DefendingPlayerControlsPredicate;
|
||||
import mage.target.TargetPermanent;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
|
|
@ -35,11 +37,19 @@ public class IcingdeathFrostTongueToken extends TokenImpl {
|
|||
cardType.add(CardType.ARTIFACT);
|
||||
color.setWhite(true);
|
||||
subtype.add(SubType.EQUIPMENT);
|
||||
|
||||
// Equipped creature gets +2/+0
|
||||
this.addAbility(new SimpleStaticAbility(new BoostEquippedEffect(2, 0)));
|
||||
|
||||
// Whenever equipped creature attacks, tap target creature defending player controls
|
||||
Ability ability = new AttacksAttachedTriggeredAbility(new TapTargetEffect(), false);
|
||||
ability.addTarget(new TargetPermanent(filter));
|
||||
this.addAbility(ability);
|
||||
|
||||
// Equip {2}
|
||||
this.addAbility(new EquipAbility(2));
|
||||
|
||||
availableImageSetCodes = Arrays.asList("AFR");
|
||||
}
|
||||
|
||||
private IcingdeathFrostTongueToken(final IcingdeathFrostTongueToken token) {
|
||||
|
|
|
|||
|
|
@ -6,6 +6,8 @@ import mage.abilities.keyword.ReachAbility;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
|
|
@ -18,8 +20,14 @@ public final class LolthSpiderToken extends TokenImpl {
|
|||
subtype.add(SubType.SPIDER);
|
||||
power = new MageInt(2);
|
||||
toughness = new MageInt(1);
|
||||
addAbility(new MenaceAbility());
|
||||
addAbility(ReachAbility.getInstance());
|
||||
|
||||
// Menace
|
||||
this.addAbility(new MenaceAbility());
|
||||
|
||||
// Reach
|
||||
this.addAbility(ReachAbility.getInstance());
|
||||
|
||||
availableImageSetCodes = Arrays.asList("AFR");
|
||||
}
|
||||
|
||||
public LolthSpiderToken(final LolthSpiderToken token) {
|
||||
|
|
|
|||
|
|
@ -4,6 +4,8 @@ import mage.MageInt;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
|
|
@ -16,6 +18,8 @@ public final class SkeletonToken extends TokenImpl {
|
|||
color.setBlack(true);
|
||||
power = new MageInt(1);
|
||||
toughness = new MageInt(1);
|
||||
|
||||
availableImageSetCodes = Arrays.asList("AFR");
|
||||
}
|
||||
|
||||
public SkeletonToken(final SkeletonToken token) {
|
||||
|
|
|
|||
|
|
@ -6,6 +6,8 @@ import mage.constants.CardType;
|
|||
import mage.constants.SubType;
|
||||
import mage.constants.SuperType;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
|
|
@ -20,7 +22,11 @@ public final class TheAtropalToken extends TokenImpl {
|
|||
subtype.add(SubType.HORROR);
|
||||
power = new MageInt(4);
|
||||
toughness = new MageInt(4);
|
||||
|
||||
// Deathtouch
|
||||
addAbility(DeathtouchAbility.getInstance());
|
||||
|
||||
availableImageSetCodes = Arrays.asList("AFR");
|
||||
}
|
||||
|
||||
public TheAtropalToken(final TheAtropalToken token) {
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ public final class TreasureToken extends TokenImpl {
|
|||
ability.addCost(new SacrificeSourceCost());
|
||||
this.addAbility(ability);
|
||||
|
||||
availableImageSetCodes = Arrays.asList("XLN", "RNA", "M20", "C19", "C20", "M21", "CMR", "KHM", "STX", "MH2");
|
||||
availableImageSetCodes = Arrays.asList("XLN", "RNA", "M20", "C19", "C20", "M21", "CMR", "KHM", "STX", "MH2", "AFR");
|
||||
}
|
||||
|
||||
public TreasureToken(final TreasureToken token) {
|
||||
|
|
|
|||
|
|
@ -6,6 +6,8 @@ import mage.constants.CardType;
|
|||
import mage.constants.SubType;
|
||||
import mage.constants.SuperType;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
|
|
@ -20,7 +22,11 @@ public final class VecnaToken extends TokenImpl {
|
|||
subtype.add(SubType.GOD);
|
||||
power = new MageInt(8);
|
||||
toughness = new MageInt(8);
|
||||
addAbility(IndestructibleAbility.getInstance());
|
||||
|
||||
// Indestructible
|
||||
this.addAbility(IndestructibleAbility.getInstance());
|
||||
|
||||
availableImageSetCodes = Arrays.asList("AFR");
|
||||
}
|
||||
|
||||
private VecnaToken(final VecnaToken token) {
|
||||
|
|
|
|||
|
|
@ -3,48 +3,35 @@ package mage.game.permanent.token;
|
|||
import mage.MageInt;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.util.RandomUtil;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author BetaSteward_at_googlemail.com
|
||||
*/
|
||||
public final class WolfToken extends TokenImpl {
|
||||
|
||||
static final private List<String> tokenImageSets = new ArrayList<>();
|
||||
|
||||
static {
|
||||
tokenImageSets.addAll(Arrays.asList("BNG", "C14", "CNS", "FNMP", "ISD", "LRW", "M10", "M14", "MM2", "SHM", "SOM",
|
||||
"ZEN", "SOI", "C15", "M15", "WAR", "M20", "THB"));
|
||||
}
|
||||
|
||||
public WolfToken() {
|
||||
this(null, 0);
|
||||
}
|
||||
|
||||
public WolfToken(String setCode) {
|
||||
this(setCode, 0);
|
||||
}
|
||||
|
||||
public WolfToken(String setCode, int tokenType) {
|
||||
super("Wolf", "2/2 green Wolf creature token");
|
||||
availableImageSetCodes = tokenImageSets;
|
||||
setOriginalExpansionSetCode(setCode);
|
||||
|
||||
cardType.add(CardType.CREATURE);
|
||||
color.setGreen(true);
|
||||
subtype.add(SubType.WOLF);
|
||||
power = new MageInt(2);
|
||||
toughness = new MageInt(2);
|
||||
|
||||
availableImageSetCodes = Arrays.asList("BNG", "C14", "C15", "CMA", "CMD", "CNS", "DKA", "EVE", "ISD",
|
||||
"LRW", "M10", "M14", "MM2", "MOR", "SHM", "SOI", "SOM", "V10", "WWK", "ZEN", "WAR", "M20",
|
||||
"THB", "AFR");
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setExpansionSetCodeForImage(String code) {
|
||||
super.setExpansionSetCodeForImage(code);
|
||||
|
||||
if (getOriginalExpansionSetCode() != null && getOriginalExpansionSetCode().equals("ISD")) {
|
||||
this.setTokenType(2);
|
||||
this.setTokenType(RandomUtil.nextInt(2) + 1); // 2 images
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ public final class ZombieToken extends TokenImpl {
|
|||
"CNS", "MMA", "BNG", "KTK", "DTK", "ORI", "OGW",
|
||||
"SOI", "EMN", "EMA", "MM3", "AKH", "CMA", "E01",
|
||||
"RNA", "WAR", "MH1", "M20", "C19", "THB", "M21",
|
||||
"CMR", "C21", "MH2");
|
||||
"CMR", "C21", "MH2", "AFR");
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue