mirror of
https://github.com/magefree/mage.git
synced 2025-12-22 03:22:00 -08:00
renamed gender class to pronoun class
This commit is contained in:
parent
47bbb70675
commit
6eda309765
10 changed files with 57 additions and 49 deletions
|
|
@ -5,7 +5,7 @@ import java.util.UUID;
|
|||
import mage.MageInt;
|
||||
import mage.ObjectColor;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.Gender;
|
||||
import mage.abilities.Pronoun;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.common.SpellCastControllerTriggeredAbility;
|
||||
import mage.abilities.condition.common.SourceDealtDamageCondition;
|
||||
|
|
@ -53,7 +53,7 @@ public final class ChandraFireOfKaladesh extends CardImpl {
|
|||
// {T}: Chandra, Fire of Kaladesh deals 1 damage to target player. If Chandra has dealt 3 or more damage this turn, exile her, then return her to the battlefield transformed under her owner's control.
|
||||
this.addAbility(new TransformAbility());
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), new TapSourceCost());
|
||||
ability.addEffect(new ConditionalOneShotEffect(new ExileAndReturnTransformedSourceEffect(Gender.FEMALE), new SourceDealtDamageCondition(3)));
|
||||
ability.addEffect(new ConditionalOneShotEffect(new ExileAndReturnTransformedSourceEffect(Pronoun.SHE), new SourceDealtDamageCondition(3)));
|
||||
ability.addTarget(new TargetPlayerOrPlaneswalker());
|
||||
this.addAbility(ability);
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
package mage.cards.c;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Gender;
|
||||
import mage.abilities.Pronoun;
|
||||
import mage.abilities.common.AttacksTriggeredAbility;
|
||||
import mage.abilities.common.delayed.AtTheEndOfCombatDelayedTriggeredAbility;
|
||||
import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect;
|
||||
|
|
@ -33,7 +33,7 @@ public final class ConquerorsGalleon extends CardImpl {
|
|||
this.addAbility(new TransformAbility());
|
||||
this.addAbility(new AttacksTriggeredAbility(
|
||||
new CreateDelayedTriggeredAbilityEffect(
|
||||
new AtTheEndOfCombatDelayedTriggeredAbility(new ExileAndReturnTransformedSourceEffect(Gender.NEUTRAL, null, true))),
|
||||
new AtTheEndOfCombatDelayedTriggeredAbility(new ExileAndReturnTransformedSourceEffect(Pronoun.IT, null, true))),
|
||||
false,
|
||||
"When {this} attacks, exile it at the end of combat, then return it to the battlefield transformed under your control."));
|
||||
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ package mage.cards.j;
|
|||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.Gender;
|
||||
import mage.abilities.Pronoun;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.condition.common.CardsInControllerGraveyardCondition;
|
||||
import mage.abilities.costs.common.TapSourceCost;
|
||||
|
|
@ -39,7 +39,7 @@ public final class JaceVrynsProdigy extends CardImpl {
|
|||
// {T}: Draw a card, then discard a card. If there are five or more cards in your graveyard, exile Jace, Vryn's Prodigy, then return him to the battefield transformed under his owner's control.
|
||||
this.addAbility(new TransformAbility());
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawDiscardControllerEffect(1, 1), new TapSourceCost());
|
||||
Effect effect = new ConditionalOneShotEffect(new ExileAndReturnTransformedSourceEffect(Gender.MALE), new CardsInControllerGraveyardCondition(5));
|
||||
Effect effect = new ConditionalOneShotEffect(new ExileAndReturnTransformedSourceEffect(Pronoun.HE), new CardsInControllerGraveyardCondition(5));
|
||||
ability.addEffect(effect);
|
||||
this.addAbility(ability);
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import java.util.UUID;
|
|||
import mage.MageInt;
|
||||
import mage.MageObjectReference;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.Gender;
|
||||
import mage.abilities.Pronoun;
|
||||
import mage.abilities.common.EndOfCombatTriggeredAbility;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.condition.Condition;
|
||||
|
|
@ -45,7 +45,7 @@ public final class KytheonHeroOfAkros extends CardImpl {
|
|||
// At end of combat, if Kytheon, Hero of Akros and at least two other creatures attacked this combat, exile Kytheon,
|
||||
// then return him to the battlefield transformed under his owner's control.
|
||||
this.addAbility(new TransformAbility());
|
||||
this.addAbility(new ConditionalInterveningIfTriggeredAbility(new EndOfCombatTriggeredAbility(new ExileAndReturnTransformedSourceEffect(Gender.MALE), false),
|
||||
this.addAbility(new ConditionalInterveningIfTriggeredAbility(new EndOfCombatTriggeredAbility(new ExileAndReturnTransformedSourceEffect(Pronoun.HE), false),
|
||||
new KytheonHeroOfAkrosCondition(), "At end of combat, if {this} and at least two other creatures attacked this combat, exile {this}, "
|
||||
+ "then return him to the battlefield transformed under his owner's control."), new AttackedOrBlockedThisCombatWatcher());
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package mage.cards.l;
|
|||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Gender;
|
||||
import mage.abilities.Pronoun;
|
||||
import mage.abilities.common.DiesCreatureTriggeredAbility;
|
||||
import mage.abilities.effects.common.CreateTokenEffect;
|
||||
import mage.abilities.effects.common.ExileAndReturnTransformedSourceEffect;
|
||||
|
|
@ -49,7 +49,7 @@ public final class LilianaHereticalHealer extends CardImpl {
|
|||
this.addAbility(LifelinkAbility.getInstance());
|
||||
|
||||
// Whenever another nontoken creature you control dies, exile Liliana Heretical Healer, then return her to the battlefield transformed under her owner's control. If you do, create a 2/2 black Zombie creature token.
|
||||
this.addAbility(new DiesCreatureTriggeredAbility(new ExileAndReturnTransformedSourceEffect(Gender.FEMALE,
|
||||
this.addAbility(new DiesCreatureTriggeredAbility(new ExileAndReturnTransformedSourceEffect(Pronoun.SHE,
|
||||
new CreateTokenEffect(new ZombieToken())), false, filter));
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ package mage.cards.n;
|
|||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Gender;
|
||||
import mage.abilities.Pronoun;
|
||||
import mage.abilities.common.ActivateAsSorceryActivatedAbility;
|
||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
|
|
@ -46,7 +46,7 @@ public final class NicolBolasTheRavager extends CardImpl {
|
|||
this.addAbility(new TransformAbility());
|
||||
this.addAbility(new ActivateAsSorceryActivatedAbility(
|
||||
Zone.BATTLEFIELD,
|
||||
new ExileAndReturnTransformedSourceEffect(Gender.MALE),
|
||||
new ExileAndReturnTransformedSourceEffect(Pronoun.HE),
|
||||
new ManaCostsImpl("{4}{U}{B}{R}")
|
||||
));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package mage.cards.n;
|
|||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Gender;
|
||||
import mage.abilities.Pronoun;
|
||||
import mage.abilities.common.EntersBattlefieldControlledTriggeredAbility;
|
||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||
import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition;
|
||||
|
|
@ -49,7 +49,7 @@ public final class NissaVastwoodSeer extends CardImpl {
|
|||
// Whenever a land enters the battlefield under your control, if you control seven or more lands, exile Nissa, then return her to the battlefield transformed under her owner's control.
|
||||
this.addAbility(new TransformAbility());
|
||||
this.addAbility(new ConditionalInterveningIfTriggeredAbility(
|
||||
new EntersBattlefieldControlledTriggeredAbility(new ExileAndReturnTransformedSourceEffect(Gender.FEMALE), new FilterLandPermanent()),
|
||||
new EntersBattlefieldControlledTriggeredAbility(new ExileAndReturnTransformedSourceEffect(Pronoun.SHE), new FilterLandPermanent()),
|
||||
new PermanentsOnTheBattlefieldCondition(new FilterLandPermanent(), ComparisonType.MORE_THAN, 6, true),
|
||||
"Whenever a land enters the battlefield under your control, if you control seven or more lands, exile {this}, then return her to the battlefield transformed under her owner's control."));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,25 +0,0 @@
|
|||
package mage.abilities;
|
||||
|
||||
/**
|
||||
* Created by IGOUDT on 5-3-2017.
|
||||
*/
|
||||
public enum Gender {
|
||||
MALE("his", "him"), FEMALE("her", "her"), NEUTRAL("its", "it");
|
||||
|
||||
String personalPronoun;
|
||||
String possesivePronoun;
|
||||
|
||||
Gender(String possessive, String personal) {
|
||||
personalPronoun = personal;
|
||||
possesivePronoun = possessive;
|
||||
}
|
||||
|
||||
public String getPersonalPronoun() {
|
||||
return personalPronoun;
|
||||
}
|
||||
|
||||
public String getPossesivePronoun() {
|
||||
return possesivePronoun;
|
||||
}
|
||||
|
||||
}
|
||||
33
Mage/src/main/java/mage/abilities/Pronoun.java
Normal file
33
Mage/src/main/java/mage/abilities/Pronoun.java
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package mage.abilities;
|
||||
|
||||
/**
|
||||
* Created by IGOUDT on 5-3-2017.
|
||||
*/
|
||||
public enum Pronoun {
|
||||
HE("he", "him", "his"),
|
||||
SHE("she", "her", "her"),
|
||||
THEY("they", "them", "their"),
|
||||
IT("it", "it", "its");
|
||||
|
||||
private final String subjective;
|
||||
private final String objective;
|
||||
private final String possessive;
|
||||
|
||||
Pronoun(String subjective, String objective, String possessive) {
|
||||
this.subjective = subjective;
|
||||
this.objective = objective;
|
||||
this.possessive = possessive;
|
||||
}
|
||||
|
||||
public String getSubjective() {
|
||||
return subjective;
|
||||
}
|
||||
|
||||
public String getObjective() {
|
||||
return objective;
|
||||
}
|
||||
|
||||
public String getPossessive() {
|
||||
return possessive;
|
||||
}
|
||||
}
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
package mage.abilities.effects.common;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.Gender;
|
||||
import mage.abilities.Pronoun;
|
||||
import mage.abilities.effects.ContinuousEffect;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
|
|
@ -22,28 +22,28 @@ public class ExileAndReturnTransformedSourceEffect extends OneShotEffect {
|
|||
protected boolean returnUnderYourControl;
|
||||
|
||||
public ExileAndReturnTransformedSourceEffect() {
|
||||
this(Gender.NEUTRAL);
|
||||
this(Pronoun.IT);
|
||||
}
|
||||
|
||||
public ExileAndReturnTransformedSourceEffect(Gender gender) {
|
||||
this(gender, null);
|
||||
public ExileAndReturnTransformedSourceEffect(Pronoun pronoun) {
|
||||
this(pronoun, null);
|
||||
}
|
||||
|
||||
public ExileAndReturnTransformedSourceEffect(Gender gender, Effect additionalEffect) {
|
||||
this(gender, additionalEffect, false);
|
||||
public ExileAndReturnTransformedSourceEffect(Pronoun pronoun, Effect additionalEffect) {
|
||||
this(pronoun, additionalEffect, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param gender
|
||||
* @param pronoun
|
||||
* @param additionalEffect that effect is applies as source is exiled
|
||||
* @param returnUnderYourControl return under your or owner control
|
||||
*/
|
||||
public ExileAndReturnTransformedSourceEffect(Gender gender, Effect additionalEffect, boolean returnUnderYourControl) {
|
||||
public ExileAndReturnTransformedSourceEffect(Pronoun pronoun, Effect additionalEffect, boolean returnUnderYourControl) {
|
||||
super(Outcome.Benefit);
|
||||
this.additionalEffect = additionalEffect;
|
||||
this.returnUnderYourControl = returnUnderYourControl;
|
||||
this.staticText = "exile {this}, then return " + gender.getPersonalPronoun()
|
||||
+ " to the battlefield transformed under " + gender.getPossesivePronoun()
|
||||
this.staticText = "exile {this}, then return " + pronoun.getObjective()
|
||||
+ " to the battlefield transformed under " + pronoun.getPossessive()
|
||||
+ " " + (this.returnUnderYourControl ? "your" : "owner's") + " control";
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue