forked from External/mage
Reworking triggered ability text generation to allow for ability words and flavor words to be added more easily (#8010)
* refactor all instances of getRule in triggered abilities using new getTriggerPrefix method * updated triggered ability rules generation * renamed method * fixed a test failure * some more refactoring * simplified some instances of ability word usage
This commit is contained in:
parent
0a31110164
commit
ca80806400
398 changed files with 946 additions and 989 deletions
|
|
@ -2,6 +2,7 @@ package mage.abilities.common;
|
|||
|
||||
import mage.abilities.TriggeredAbilityImpl;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.constants.AbilityWord;
|
||||
import mage.constants.SetTargetPointer;
|
||||
import mage.constants.Zone;
|
||||
import mage.game.Game;
|
||||
|
|
@ -32,6 +33,7 @@ public class LandfallAbility extends TriggeredAbilityImpl {
|
|||
public LandfallAbility(Zone zone, Effect effect, boolean optional, SetTargetPointer setTargetPointer) {
|
||||
super(zone, effect, optional);
|
||||
this.setTargetPointer = setTargetPointer;
|
||||
this.setAbilityWord(AbilityWord.LANDFALL);
|
||||
}
|
||||
|
||||
public LandfallAbility(final LandfallAbility ability) {
|
||||
|
|
@ -63,8 +65,8 @@ public class LandfallAbility extends TriggeredAbilityImpl {
|
|||
}
|
||||
|
||||
@Override
|
||||
public String getRule() {
|
||||
return "<i>Landfall</i> — Whenever a land enters the battlefield under your control, " + super.getRule();
|
||||
public String getTriggerPhrase() {
|
||||
return "Whenever a land enters the battlefield under your control, ";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue