forked from External/mage
Replace Overriden getTriggerPhrase() with setTriggerPhrase() usage (#9343)
This commit is contained in:
parent
188e6dd8c1
commit
ebdb6b53a4
406 changed files with 918 additions and 2665 deletions
|
|
@ -19,8 +19,8 @@ import java.util.UUID;
|
|||
*/
|
||||
public class AttacksAllTriggeredAbility extends TriggeredAbilityImpl {
|
||||
|
||||
protected FilterCreaturePermanent filter;
|
||||
protected boolean attacksYouOrYourPlaneswalker;
|
||||
protected final FilterCreaturePermanent filter;
|
||||
protected final boolean attacksYouOrYourPlaneswalker;
|
||||
protected SetTargetPointer setTargetPointer;
|
||||
protected boolean controller;
|
||||
|
||||
|
|
@ -42,11 +42,13 @@ public class AttacksAllTriggeredAbility extends TriggeredAbilityImpl {
|
|||
this.attacksYouOrYourPlaneswalker = attacksYouOrYourPlaneswalker;
|
||||
this.setTargetPointer = setTargetPointer;
|
||||
this.controller = controller;
|
||||
setTriggerPhrase("Whenever " + CardUtil.addArticle(filter.getMessage()) + " attacks"
|
||||
+ (attacksYouOrYourPlaneswalker ? " you or a planeswalker you control" : "") + ", ");
|
||||
}
|
||||
|
||||
public AttacksAllTriggeredAbility(final AttacksAllTriggeredAbility ability) {
|
||||
super(ability);
|
||||
this.filter = ability.filter.copy();
|
||||
this.filter = ability.filter; // TODO: Does this have to be a copy?
|
||||
this.attacksYouOrYourPlaneswalker = ability.attacksYouOrYourPlaneswalker;
|
||||
this.setTargetPointer = ability.setTargetPointer;
|
||||
this.controller = ability.controller;
|
||||
|
|
@ -96,11 +98,4 @@ public class AttacksAllTriggeredAbility extends TriggeredAbilityImpl {
|
|||
public AttacksAllTriggeredAbility copy() {
|
||||
return new AttacksAllTriggeredAbility(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getTriggerPhrase() {
|
||||
return "Whenever " + CardUtil.addArticle(filter.getMessage()) + " attacks"
|
||||
+ (attacksYouOrYourPlaneswalker ? " you or a planeswalker you control" : "") + ", ";
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue