mirror of
https://github.com/magefree/mage.git
synced 2025-12-24 20:41:58 -08:00
Oracle Text fixes. NPE fixes
This commit is contained in:
parent
d3f1f811ce
commit
04de56860a
8 changed files with 45 additions and 27 deletions
|
|
@ -13,10 +13,18 @@ import mage.util.CardUtil;
|
|||
public class VanishingUpkeepAbility extends BeginningOfUpkeepTriggeredAbility {
|
||||
|
||||
private int vanishingAmount;
|
||||
private String permanentType;
|
||||
|
||||
public VanishingUpkeepAbility(int vanishingEffect) {
|
||||
super(new VanishingEffect(), TargetController.YOU, false);
|
||||
this.vanishingAmount = vanishingEffect;
|
||||
this.permanentType = "creature";
|
||||
}
|
||||
|
||||
public VanishingUpkeepAbility(int vanishingEffect, String permanentType) {
|
||||
super(new VanishingEffect(), TargetController.YOU, false);
|
||||
this.vanishingAmount = vanishingEffect;
|
||||
this.permanentType = permanentType;
|
||||
}
|
||||
|
||||
public VanishingUpkeepAbility(final VanishingUpkeepAbility ability) {
|
||||
|
|
@ -33,11 +41,11 @@ public class VanishingUpkeepAbility extends BeginningOfUpkeepTriggeredAbility {
|
|||
public String getRule() {
|
||||
if(vanishingAmount > 0) {
|
||||
return "Vanishing " + vanishingAmount
|
||||
+ " <i>(This permanent enters the battlefield with " + CardUtil.numberToText(vanishingAmount)
|
||||
+ " <i>(This " + permanentType + " enters the battlefield with " + CardUtil.numberToText(vanishingAmount)
|
||||
+ " time counters on it. At the beginning of your upkeep, remove a time counter from it. When the last is removed, sacrifice it.)</i>";
|
||||
}
|
||||
else {
|
||||
return "Vanishing <i>(At the beginning of your upkeep, remove a time counter from this permanent. When the last is removed, sacrifice it.)</i>";
|
||||
return "Vanishing <i>(At the beginning of your upkeep, remove a time counter from this " + permanentType + ". When the last is removed, sacrifice it.)</i>";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,7 +31,6 @@ package mage.game.permanent.token;
|
|||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.constants.CardType;
|
||||
|
||||
|
|
@ -44,7 +43,7 @@ public class InsectToken extends Token {
|
|||
final static private List<String> tokenImageSets = new ArrayList<>();
|
||||
|
||||
static {
|
||||
tokenImageSets.addAll(Arrays.asList("M10", "MM2"));
|
||||
tokenImageSets.addAll(Arrays.asList("M10", "MM2", "SOI"));
|
||||
}
|
||||
|
||||
public InsectToken() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue