Fixed that alternative spell always selected to cast if available;

This commit is contained in:
Oleg Agafonov 2019-06-23 17:20:04 +04:00
parent 4bf9153bc2
commit 63a9a505e1
8 changed files with 62 additions and 2 deletions

View file

@ -12,6 +12,7 @@ public class CastCommanderAbility extends SpellAbility {
public CastCommanderAbility(Card card) {
super(card.getSpellAbility());
this.newId();
this.setCardName(cardName = card.getName());
zone = Zone.COMMAND;
spellAbilityType = SpellAbilityType.BASE;

View file

@ -38,6 +38,7 @@ public class AwakenAbility extends SpellAbility {
public AwakenAbility(Card card, int awakenValue, String awakenCosts) {
super(card.getSpellAbility());
this.newId();
this.setCardName(card.getName() + " with awaken");
zone = Zone.HAND;
spellAbilityType = SpellAbilityType.BASE_ALTERNATE;

View file

@ -30,6 +30,7 @@ public class EmergeAbility extends SpellAbility {
public EmergeAbility(Card card, ManaCosts<ManaCost> emergeCost) {
super(card.getSpellAbility());
this.newId();
this.setCardName(card.getName() + " with emerge");
zone = Zone.HAND;
spellAbilityType = SpellAbilityType.BASE_ALTERNATE;

View file

@ -37,6 +37,7 @@ public class JumpStartAbility extends SpellAbility {
public JumpStartAbility(Card card) {
super(card.getSpellAbility());
this.newId();
this.setCardName(card.getName() + " with jump-start");
zone = Zone.GRAVEYARD;
spellAbilityType = SpellAbilityType.BASE_ALTERNATE;

View file

@ -16,6 +16,7 @@ public class RetraceAbility extends SpellAbility {
public RetraceAbility(Card card) {
super(card.getSpellAbility());
this.newId();
this.setCardName(card.getName() + " with retrace");
zone = Zone.GRAVEYARD;
spellAbilityType = SpellAbilityType.BASE_ALTERNATE;

View file

@ -23,6 +23,7 @@ public class SpectacleAbility extends SpellAbility {
public SpectacleAbility(Card card, ManaCost spectacleCosts) {
super(card.getSpellAbility());
this.newId();
this.setCardName(card.getName() + " with spectacle");
zone = Zone.HAND;
spellAbilityType = SpellAbilityType.BASE_ALTERNATE;

View file

@ -23,6 +23,7 @@ public class SurgeAbility extends SpellAbility {
public SurgeAbility(Card card, String surgeCosts) {
super(card.getSpellAbility());
this.newId();
this.setCardName(card.getName() + " with surge");
zone = Zone.HAND;
spellAbilityType = SpellAbilityType.BASE_ALTERNATE;