small change in gender enum

This commit is contained in:
ingmargoudt 2017-03-06 10:18:16 +01:00
parent 80814b457c
commit 6d4c388c5e
7 changed files with 37 additions and 14 deletions

View file

@ -0,0 +1,26 @@
package mage.abilities;
/**
* Created by IGOUDT on 5-3-2017.
*/
public enum Gender {
MALE("his", "him"), FEMALE("her", "her");
String personalPronoun;
String possesivePronoun;
Gender(String possessive, String personal) {
personalPronoun = personal;
possesivePronoun = possessive;
}
public String getPersonalPronoun() {
return personalPronoun;
}
public String getPossesivePronoun() {
return possesivePronoun;
}
}

View file

@ -6,6 +6,7 @@
package mage.abilities.effects.common;
import mage.abilities.Ability;
import mage.abilities.Gender;
import mage.abilities.effects.ContinuousEffect;
import mage.abilities.effects.Effect;
import mage.abilities.effects.OneShotEffect;
@ -18,15 +19,10 @@ import mage.game.permanent.Permanent;
import mage.players.Player;
/**
*
* @author LevelX2
*/
public class ExileAndReturnTransformedSourceEffect extends OneShotEffect {
public static enum Gender {
MALE, FEMAL
}
protected Effect additionalEffect;
@ -41,8 +37,8 @@ public class ExileAndReturnTransformedSourceEffect extends OneShotEffect {
public ExileAndReturnTransformedSourceEffect(Gender gender, Effect additionalEffect) {
super(Outcome.Benefit);
this.additionalEffect = additionalEffect;
this.staticText = "exile {this}, then return " + (gender.equals(Gender.MALE) ? "him" : "her")
+ " to the battlefield transformed under " + (gender.equals(Gender.MALE) ? "his" : "her") + " owner's control";
this.staticText = "exile {this}, then return " + gender.getPersonalPronoun()
+ " to the battlefield transformed under " + gender.getPossesivePronoun() + " owner's control";
}
public ExileAndReturnTransformedSourceEffect(final ExileAndReturnTransformedSourceEffect effect) {