mirror of
https://github.com/correl/mage.git
synced 2024-11-28 19:19:55 +00:00
[J22] Implement Chains of Custody (#9958)
* chains of custody j22 * add to set list * set number * set text and capitalization * remove extra ;
This commit is contained in:
parent
31cb9b086b
commit
ad4d4e4b92
2 changed files with 67 additions and 0 deletions
66
Mage.Sets/src/mage/cards/c/ChainsOfCustody.java
Normal file
66
Mage.Sets/src/mage/cards/c/ChainsOfCustody.java
Normal file
|
@ -0,0 +1,66 @@
|
|||
package mage.cards.c;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.costs.mana.GenericManaCost;
|
||||
import mage.abilities.effects.common.AttachEffect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect;
|
||||
import mage.abilities.keyword.EnchantAbility;
|
||||
import mage.abilities.keyword.WardAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.AttachmentType;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SubType;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.target.TargetPermanent;
|
||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||
import mage.abilities.common.delayed.OnLeaveReturnExiledToBattlefieldAbility;
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect;
|
||||
import mage.abilities.effects.common.ExileUntilSourceLeavesEffect;
|
||||
/**
|
||||
|
||||
* @author Chesse20
|
||||
*/
|
||||
public final class ChainsOfCustody extends CardImpl {
|
||||
|
||||
|
||||
public ChainsOfCustody(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}");
|
||||
|
||||
this.subtype.add(SubType.AURA);
|
||||
|
||||
// Enchant creature *YOU* control
|
||||
TargetPermanent auraTarget = new TargetPermanent(StaticFilters.FILTER_CONTROLLED_CREATURE); //only your creatures!
|
||||
this.getSpellAbility().addTarget(auraTarget);
|
||||
this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature));
|
||||
this.addAbility(new EnchantAbility(auraTarget));
|
||||
|
||||
//exile until leaves the battlefield
|
||||
Ability ability = new EnchantAbility(auraTarget);
|
||||
ability = new EntersBattlefieldTriggeredAbility(new ExileUntilSourceLeavesEffect());
|
||||
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_OPPONENTS_PERMANENT_NON_LAND)); //more than just creatures
|
||||
ability.addEffect(new CreateDelayedTriggeredAbilityEffect(new OnLeaveReturnExiledToBattlefieldAbility()));
|
||||
this.addAbility(ability);
|
||||
|
||||
// ward 2
|
||||
this.addAbility(new SimpleStaticAbility(
|
||||
new GainAbilityAttachedEffect(
|
||||
new WardAbility(new GenericManaCost(2), false), AttachmentType.AURA
|
||||
).setText("Enchanted creature has ward {2}.")
|
||||
));
|
||||
|
||||
|
||||
}
|
||||
|
||||
private ChainsOfCustody(final ChainsOfCustody card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ChainsOfCustody copy() {
|
||||
return new ChainsOfCustody(this);
|
||||
}
|
||||
}
|
|
@ -130,6 +130,7 @@ public final class Jumpstart2022 extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Cellar Door", 759, Rarity.UNCOMMON, mage.cards.c.CellarDoor.class));
|
||||
cards.add(new SetCardInfo("Cemetery Recruitment", 385, Rarity.COMMON, mage.cards.c.CemeteryRecruitment.class));
|
||||
cards.add(new SetCardInfo("Certain Death", 386, Rarity.COMMON, mage.cards.c.CertainDeath.class));
|
||||
cards.add(new SetCardInfo("Chains of Custody", 3, Rarity.COMMON, mage.cards.c.ChainsOfCustody.class));
|
||||
cards.add(new SetCardInfo("Challenger Troll", 639, Rarity.UNCOMMON, mage.cards.c.ChallengerTroll.class));
|
||||
cards.add(new SetCardInfo("Chandra's Magmutt", 512, Rarity.COMMON, mage.cards.c.ChandrasMagmutt.class));
|
||||
cards.add(new SetCardInfo("Chandra's Pyreling", 513, Rarity.UNCOMMON, mage.cards.c.ChandrasPyreling.class));
|
||||
|
|
Loading…
Reference in a new issue