예제 #1
0
 public Town(
     String ID,
     String Country,
     String Mayor,
     Plot TownHallPlot,
     String TT,
     Integer TaxRate,
     Boolean PVP,
     Boolean FreeBuild,
     Location SpawnLocation,
     Integer Coffers,
     Integer Health,
     String Color,
     String MOTD,
     Integer Size) {
   super(ID);
   setCountry(Country);
   setMayor(Mayor);
   setTownHallPlot(TownHallPlot);
   setTaxType(TaxType.valueOf(TT.toUpperCase()));
   setTax(TaxRate);
   setPVPAllowed(PVP);
   setFreeBuildAllowed(FreeBuild);
   setSpawnLocation(SpawnLocation);
   setCoffers(Coffers);
   setHealth(Health);
   setColor(ChatColor.valueOf(Color));
   setMOTD(MOTD);
   setSize(Size);
   setFormattedID(this.getColor() + this.getID() + Main.messageColor);
 }
 @Override
 public TaxType getType() {
   return TaxType.getInstance(this.type);
 }
 @Override
 public void setType(TaxType type) {
   this.type = type.getType();
 }
 public TaxDetailImpl(TaxType type, Money amount, BigDecimal rate) {
   this.type = type.getType();
   this.amount = amount.getAmount();
   this.rate = rate;
 }