This commit is contained in:
Jeff Wadsworth 2022-10-19 14:57:03 -05:00
parent fadcd3f00a
commit 75c39c87be
10 changed files with 91 additions and 20 deletions

View file

@ -17,7 +17,6 @@ import mage.constants.*;
import mage.game.Game;
import mage.game.events.DamagedPlayerEvent;
import mage.game.events.GameEvent;
import mage.game.events.GameEvent.EventType;
import mage.game.permanent.Permanent;
import mage.game.permanent.token.TokenImpl;

View file

@ -16,12 +16,12 @@ import mage.constants.SubType;
import mage.filter.StaticFilters;
import mage.game.Controllable;
import mage.game.Game;
import mage.game.permanent.token.AstartesWarriorToken;
import java.util.Map;
import java.util.UUID;
import java.util.function.Function;
import java.util.stream.Collectors;
import mage.game.permanent.token.WhiteAstartesWarriorToken;
/**
* @author TheElk801
@ -39,7 +39,7 @@ public final class BirthOfTheImperium extends CardImpl {
// I -- Create a 2/2 white Astartes Warrior creature token with vigilance for each opponent you have.
sagaAbility.addChapterEffect(
this, SagaChapter.CHAPTER_I,
new CreateTokenEffect(new AstartesWarriorToken(), OpponentsCount.instance)
new CreateTokenEffect(new WhiteAstartesWarriorToken(), OpponentsCount.instance)
.setText("create a 2/2 white Astartes Warrior creature " +
"token with vigilance for each opponent you have")
);

View file

@ -18,9 +18,9 @@ import mage.constants.CardType;
import mage.constants.ComparisonType;
import mage.constants.Zone;
import mage.filter.StaticFilters;
import mage.game.permanent.token.AstartesWarriorToken;
import java.util.UUID;
import mage.game.permanent.token.WhiteAstartesWarriorToken;
/**
* @author TheElk801
@ -40,14 +40,14 @@ public final class DefendersOfHumanity extends CardImpl {
// When Defenders of Humanity enters the battlefield, create X 2/2 white Astartes Warrior creature tokens with vigilance.
this.addAbility(new EntersBattlefieldTriggeredAbility(
new CreateTokenEffect(new AstartesWarriorToken(), ManacostVariableValue.ETB)
new CreateTokenEffect(new WhiteAstartesWarriorToken(), ManacostVariableValue.ETB)
));
// {X}{2}{W}, Exile Defenders of Humanity: Create X 2/2 white Astartes Warrior creature tokens with vigilance. Activate only if you control no creatures and only during your turn.
this.addAbility(new ActivateIfConditionActivatedAbility(
Zone.BATTLEFIELD,
new CreateTokenEffect(
new AstartesWarriorToken(), GetXValue.instance
new WhiteAstartesWarriorToken(), GetXValue.instance
), new ManaCostsImpl<>("{X}{2}{W}"), condition
).addHint(CreaturesYouControlHint.instance).addHint(MyTurnHint.instance));
}

View file

@ -12,9 +12,9 @@ import mage.constants.CardType;
import mage.constants.Duration;
import mage.constants.SubType;
import mage.filter.StaticFilters;
import mage.game.permanent.token.AstartesWarriorToken;
import java.util.UUID;
import mage.game.permanent.token.WhiteAstartesWarriorToken;
/**
* @author TheElk801
@ -28,7 +28,7 @@ public final class InquisitorialRosette extends CardImpl {
// Inquisition Agents -- Whenever equipped creature attacks, create a 2/2 white Astartes Warrior creature token with vigilance that's attacking. Then attacking creatures gain menace until end of turn.
Ability ability = new AttacksAttachedTriggeredAbility(
new CreateTokenEffect(new AstartesWarriorToken(), 1, false, true)
new CreateTokenEffect(new WhiteAstartesWarriorToken(), 1, false, true)
);
ability.addEffect(new GainAbilityAllEffect(
new MenaceAbility(false), Duration.EndOfTurn,

View file

@ -17,10 +17,10 @@ import mage.game.Game;
import mage.game.events.GameEvent;
import mage.game.events.ZoneChangeGroupEvent;
import mage.game.permanent.PermanentImpl;
import mage.game.permanent.token.AstartesWarriorToken;
import java.util.Objects;
import java.util.UUID;
import mage.game.permanent.token.WhiteAstartesWarriorToken;
/**
* @author PurpleCrowbar
@ -43,7 +43,7 @@ public final class MarneusCalgar extends CardImpl {
// Chapter Master {6}: Create two 2/2 white Astartes Warrior creature tokens with vigilance.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD,
new CreateTokenEffect(new AstartesWarriorToken(), 2),
new CreateTokenEffect(new WhiteAstartesWarriorToken(), 2),
new ManaCostsImpl<>("{6}")
).withFlavorWord("Chapter Master"));
}
@ -81,11 +81,11 @@ class MarneusCalgarTriggeredAbility extends TriggeredAbilityImpl {
return Zone.BATTLEFIELD == zEvent.getToZone()
&& zEvent.getTokens() != null
&& zEvent
.getTokens()
.stream()
.filter(Objects::nonNull)
.map(PermanentImpl::getControllerId)
.anyMatch(this::isControlledBy);
.getTokens()
.stream()
.filter(Objects::nonNull)
.map(PermanentImpl::getControllerId)
.anyMatch(this::isControlledBy);
}
@Override

View file

@ -9,12 +9,12 @@ import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.*;
import mage.game.Game;
import mage.game.permanent.token.AstartesWarriorToken;
import mage.players.Player;
import mage.util.ManaUtil;
import mage.watchers.common.PlayerLostLifeWatcher;
import java.util.UUID;
import mage.game.permanent.token.BlackAstartesWarriorToken;
/**
* @author TheElk801
@ -79,6 +79,6 @@ class MortarionDaemonPrimarchEffect extends OneShotEffect {
int manaPaid = ManaUtil.playerPaysXGenericMana(
true, "Mortarion, Daemon Primarch", player, source, game, lifeLost
);
return manaPaid > 0 && new AstartesWarriorToken().putOntoBattlefield(manaPaid, game, source);
return manaPaid > 0 && new BlackAstartesWarriorToken().putOntoBattlefield(manaPaid, game, source);
}
}

View file

@ -13,9 +13,9 @@ import mage.constants.CardType;
import mage.constants.Duration;
import mage.constants.SubType;
import mage.filter.StaticFilters;
import mage.game.permanent.token.AstartesWarriorToken;
import java.util.UUID;
import mage.game.permanent.token.WhiteAstartesWarriorToken;
/**
* @author TheElk801
@ -34,7 +34,7 @@ public final class ThunderhawkGunship extends CardImpl {
// When Thunderhawk Gunship enters the battlefield, create two 2/2 white Astartes Warrior creature tokens with vigilance.
this.addAbility(new EntersBattlefieldTriggeredAbility(
new CreateTokenEffect(new AstartesWarriorToken(), 2)
new CreateTokenEffect(new WhiteAstartesWarriorToken(), 2)
));
// Whenever Thunderhawk Gunship attacks, attacking creatures you control gain flying until end of turn.

View file

@ -0,0 +1,36 @@
package mage.game.permanent.token;
import mage.MageInt;
import mage.constants.CardType;
import mage.constants.SubType;
import java.util.Arrays;
import mage.abilities.keyword.MenaceAbility;
/**
* @author TheElk801
*/
public final class BlackAstartesWarriorToken extends TokenImpl {
public BlackAstartesWarriorToken() {
super("Astartes Warrior Token", "2/2 black Astartes Warrior creature tokens with menace");
cardType.add(CardType.CREATURE);
color.setBlack(true);
subtype.add(SubType.ASTARTES);
subtype.add(SubType.WARRIOR);
power = new MageInt(2);
toughness = new MageInt(2);
addAbility(new MenaceAbility());
availableImageSetCodes.addAll(Arrays.asList("40K"));
}
public BlackAstartesWarriorToken(final BlackAstartesWarriorToken token) {
super(token);
}
@Override
public BlackAstartesWarriorToken copy() {
return new BlackAstartesWarriorToken(this);
}
}

View file

@ -0,0 +1,36 @@
package mage.game.permanent.token;
import mage.MageInt;
import mage.abilities.keyword.VigilanceAbility;
import mage.constants.CardType;
import mage.constants.SubType;
import java.util.Arrays;
/**
* @author TheElk801
*/
public final class WhiteAstartesWarriorToken extends TokenImpl {
public WhiteAstartesWarriorToken() {
super("Astartes Warrior Token", "2/2 white Astartes Warrior creature tokens with vigilance");
cardType.add(CardType.CREATURE);
color.setWhite(true);
subtype.add(SubType.ASTARTES);
subtype.add(SubType.WARRIOR);
power = new MageInt(2);
toughness = new MageInt(2);
addAbility(VigilanceAbility.getInstance());
availableImageSetCodes.addAll(Arrays.asList("40K"));
}
public WhiteAstartesWarriorToken(final WhiteAstartesWarriorToken token) {
super(token);
}
@Override
public WhiteAstartesWarriorToken copy() {
return new WhiteAstartesWarriorToken(this);
}
}

View file

@ -54,7 +54,7 @@ public class FixedTarget extends TargetPointerImpl {
}
/**
* Target counter is immediatly initialised with current zoneChangeCounter
* Target counter is immediately initialized with current zoneChangeCounter
* value from the given permanent
*
* @param permanent