forked from External/mage
* UI: added playable/activatable cards highlight in all zone and windows (mana abilities, commander, graveyard, revealed, etc);
This commit is contained in:
parent
fe52ffd56a
commit
f6123037ec
15 changed files with 302 additions and 192 deletions
|
|
@ -1,10 +1,11 @@
|
|||
package mage.view;
|
||||
|
||||
import mage.cards.Card;
|
||||
import mage.game.command.Plane;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
import mage.cards.Card;
|
||||
import mage.game.command.Plane;
|
||||
|
||||
/**
|
||||
* @author spjspj
|
||||
|
|
@ -16,23 +17,24 @@ public class PlaneView implements CommandObjectView, Serializable {
|
|||
protected String expansionSetCode;
|
||||
protected List<String> rules;
|
||||
|
||||
public PlaneView(Plane plane, Card sourceCard) {
|
||||
id = plane.getId();
|
||||
name = "Plane " + sourceCard.getName();
|
||||
if (plane.getExpansionSetCodeForImage() == null) {
|
||||
expansionSetCode = sourceCard.getExpansionSetCode();
|
||||
} else {
|
||||
expansionSetCode = plane.getExpansionSetCodeForImage();
|
||||
}
|
||||
protected boolean isPlayable = false;
|
||||
|
||||
rules = plane.getAbilities().getRules(sourceCard.getName());
|
||||
public PlaneView(Plane plane, Card sourceCard) {
|
||||
this.id = plane.getId();
|
||||
this.name = "Plane " + sourceCard.getName();
|
||||
if (plane.getExpansionSetCodeForImage() == null) {
|
||||
this.expansionSetCode = sourceCard.getExpansionSetCode();
|
||||
} else {
|
||||
this.expansionSetCode = plane.getExpansionSetCodeForImage();
|
||||
}
|
||||
this.rules = plane.getAbilities().getRules(sourceCard.getName());
|
||||
}
|
||||
|
||||
public PlaneView(Plane plane) {
|
||||
id = plane.getId();
|
||||
name = plane.getName();
|
||||
expansionSetCode = plane.getExpansionSetCodeForImage();
|
||||
rules = plane.getAbilities().getRules(plane.getName());
|
||||
this.id = plane.getId();
|
||||
this.name = plane.getName();
|
||||
this.expansionSetCode = plane.getExpansionSetCodeForImage();
|
||||
this.rules = plane.getAbilities().getRules(plane.getName());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
@ -54,4 +56,36 @@ public class PlaneView implements CommandObjectView, Serializable {
|
|||
public List<String> getRules() {
|
||||
return rules;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isPlayable() {
|
||||
return isPlayable;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setPlayable(boolean isPlayable) {
|
||||
this.isPlayable = isPlayable;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isChoosable() {
|
||||
// unsupported
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setChoosable(boolean isChoosable) {
|
||||
// unsupported
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isSelected() {
|
||||
// unsupported
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setSelected(boolean selected) {
|
||||
// unsupported
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue