Fix: Fixed "toString" Methods For Most Classes + AsciiTable.java Attempted Fix.

This commit is contained in:
GabrieleRadice
2026-04-26 17:15:20 +02:00
parent d707f16d0b
commit ef82b21718
10 changed files with 25 additions and 11 deletions
@@ -230,7 +230,7 @@ public class Player implements Serializable {
// region Functions
@Override
public String toString() {
int Last = 5;
int Last = 6;
var table = new AsciiTable(UNICODE, 1);
@@ -241,6 +241,9 @@ public class Player implements Serializable {
table.addRow("Prestige: " + this.getPrestigeValue());
if(!this.hunters.isEmpty()){
Last = 6;
}
else if(!this.inventors.isEmpty()){
Last = 5;
}
else if(!this.shamans.isEmpty()){
@@ -252,7 +255,7 @@ public class Player implements Serializable {
else if(!this.builders.isEmpty()){
Last = 2;
}
else if(!this.inventors.isEmpty()){
else if(!this.artists.isEmpty()){
Last = 1;
}
else{
@@ -291,6 +294,13 @@ public class Player implements Serializable {
table.addRow("Shamans: " + this.shamans.toString());
}
if(!this.inventors.isEmpty()){
if(Last == 5){
table.addSeparator();
}
table.addRow("Inventors: " + this.inventors.toString());
}
if(!this.hunters.isEmpty()){
table.addSeparator();