* GUI: new reworked GUI and card render engine, card icons and dozens of other fixes (see full list in related PR);

This commit is contained in:
Oleg Agafonov 2021-01-30 16:38:55 +04:00
parent df98cc3e62
commit a1da5ef437
304 changed files with 7266 additions and 5093 deletions

View file

@ -2,6 +2,7 @@ package mage.view;
import mage.cards.Card;
import mage.game.command.Emblem;
import mage.players.PlayableObjectStats;
import java.io.Serializable;
import java.util.List;
@ -16,8 +17,7 @@ public class EmblemView implements CommandObjectView, Serializable {
protected String name;
protected String expansionSetCode;
protected List<String> rules;
protected boolean isPlayable = false;
protected int playableAmount = 0;
protected PlayableObjectStats playableStats = new PlayableObjectStats();
public EmblemView(Emblem emblem, Card sourceCard) {
this.id = emblem.getId();
@ -57,25 +57,19 @@ public class EmblemView implements CommandObjectView, Serializable {
return rules;
}
@Override
public boolean isPlayable() {
return isPlayable;
return this.playableStats.getPlayableAmount() > 0;
}
@Override
public void setPlayable(boolean isPlayable) {
this.isPlayable = isPlayable;
public void setPlayableStats(PlayableObjectStats playableStats) {
this.playableStats = playableStats;
}
@Override
public void setPlayableAmount(int playableAmount) {
this.playableAmount = playableAmount;
}
@Override
public int getPlayableAmount() {
return playableAmount;
public PlayableObjectStats getPlayableStats() {
return this.playableStats;
}
@Override