Fixed: Character NMin
This commit is contained in:
@@ -7,7 +7,16 @@ public abstract class TribeCard extends PlayableCard {
|
||||
public boolean IsEventCard() {
|
||||
return isEventCard;
|
||||
}
|
||||
|
||||
private int nMin=0;
|
||||
public int getNMin() {
|
||||
return nMin;
|
||||
}
|
||||
public TribeCard(int Era,boolean IsEventCard) {
|
||||
super(Era);
|
||||
}
|
||||
public TribeCard(int Era,boolean IsEventCard,int nMin) {
|
||||
super(Era);
|
||||
this.nMin=nMin;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,6 +14,10 @@ public abstract class Character extends TribeCard implements Cloneable {
|
||||
super(Era,false );
|
||||
this.type = type;
|
||||
}
|
||||
public Character(int Era, CharacterType type,int nMin){
|
||||
super(Era,false ,nMin);
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
|
||||
@@ -13,6 +13,9 @@ public class Artist extends Character {
|
||||
public Artist(int Era) {
|
||||
super(Era, CharacterType.ARTIST);
|
||||
}
|
||||
public Artist(int Era,int nMin) {
|
||||
super(Era, CharacterType.ARTIST,nMin);
|
||||
}
|
||||
|
||||
public Artist(Artist copy){
|
||||
this(copy.getEra());
|
||||
|
||||
@@ -31,6 +31,19 @@ public class Builder extends Character
|
||||
}
|
||||
this.prestigeValue = prestigeValue;
|
||||
}
|
||||
|
||||
public Builder(int Era, int reductionValue, int prestigeValue,int nMin) throws IllegalArgumentException {
|
||||
super(Era,CharacterType.BUILDER,nMin);
|
||||
if(reductionValue < 0) {
|
||||
throw new IllegalArgumentException();
|
||||
}
|
||||
this.reductionValue = reductionValue;
|
||||
|
||||
if(prestigeValue < 0) {
|
||||
throw new IllegalArgumentException();
|
||||
}
|
||||
this.prestigeValue = prestigeValue;
|
||||
}
|
||||
public Builder(Builder copy)
|
||||
{
|
||||
this(copy.getEra(),copy.getReductionValue(), copy.getPrestigeValue());
|
||||
|
||||
@@ -13,6 +13,9 @@ public class Gatherers extends Character {
|
||||
public Gatherers(int Era) {
|
||||
super(Era, CharacterType.GATHERERS);
|
||||
}
|
||||
public Gatherers(int Era,int nMin) {
|
||||
super(Era, CharacterType.GATHERERS,nMin);
|
||||
}
|
||||
@Override
|
||||
public String toString() {
|
||||
return super.toString();
|
||||
|
||||
@@ -24,6 +24,10 @@ public class Hunter extends Character {
|
||||
super(Era, CharacterType.HUNTER);
|
||||
this.icon = icon;
|
||||
}
|
||||
public Hunter(int Era, boolean icon, int nMin) {
|
||||
super(Era, CharacterType.HUNTER,nMin);
|
||||
this.icon = icon;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
|
||||
@@ -26,6 +26,12 @@ public class Inventor extends Character {
|
||||
throw new IllegalArgumentException();
|
||||
this.icon = icon;
|
||||
}
|
||||
public Inventor(int Era,int icon,int nMin) throws IllegalArgumentException {
|
||||
super(Era, CharacterType.INVENTOR,nMin);
|
||||
if(icon<0 || icon>9)
|
||||
throw new IllegalArgumentException();
|
||||
this.icon = icon;
|
||||
}
|
||||
@Override
|
||||
public String toString() {
|
||||
return super.toString() + " Symbol:" + String.valueOf(icon);
|
||||
|
||||
@@ -26,6 +26,10 @@ public class Shaman extends Character {
|
||||
super(Era, CharacterType.SHAMAN);
|
||||
this.icon = icon;
|
||||
}
|
||||
public Shaman(int Era, int icon, int nMin) {
|
||||
super(Era, CharacterType.SHAMAN,nMin);
|
||||
this.icon = icon;
|
||||
}
|
||||
@Override
|
||||
public String toString() {
|
||||
return super.toString() + "icon: " + String.valueOf(icon);
|
||||
|
||||
Reference in New Issue
Block a user