Browse Source

refactoring: created String for integrated Location Wald

remotes/origin/map
Tanja Herche 2 years ago
parent
commit
48c3dd29a0
  1. 13
      src/main/java/org/bitbiome/commands/MapCommand.java

13
src/main/java/org/bitbiome/commands/MapCommand.java

@ -19,6 +19,7 @@ public class MapCommand implements CommandAPI{
String locationGruenland = locations.getJSONObject(4).getString("name");
String locationWinterland = locations.getJSONObject(2).getString("name");
String locationStrand = locations.getJSONObject(1).getString("name");
String locationWald = locations.getJSONObject(0).getString("name");
if (travelEngine.getPlayer().getLocation().getName().equalsIgnoreCase("Wald")) {
outputMessage
.append(Colors.ANSI_BLUE + getLocationMessage(travelEngine) + "\n" + Colors.ANSI_RESET + "Zu den " + Colors.ANSI_BLUE + "blau " + Colors.ANSI_RESET + "markierten Standorten kannst du reisen\n" + Colors.ANSI_RESET)
@ -31,7 +32,7 @@ public class MapCommand implements CommandAPI{
.append("|________________________________|________________________________|________________________________|\n")
.append("| | | |\n")
.append("| | | |\n")
.append("| " + Colors.ANSI_BLUE + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_GREEN + locations.getJSONObject(0).getString("name") + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| " + Colors.ANSI_BLUE + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_GREEN + locationWald + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| | | |\n")
.append("|________________________________|________________________________|________________________________|\n");
} else if (travelEngine.getPlayer().getLocation().getName().equalsIgnoreCase("Strand")) {
@ -46,7 +47,7 @@ public class MapCommand implements CommandAPI{
.append("|________________________________|________________________________|________________________________|\n")
.append("| | | |\n")
.append("| | | |\n")
.append("| " + Colors.ANSI_GREEN + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locations.getJSONObject(0).getString("name") + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| " + Colors.ANSI_GREEN + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locationWald + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| | | |\n")
.append("|________________________________|________________________________|________________________________|\n");
@ -62,7 +63,7 @@ public class MapCommand implements CommandAPI{
.append("|________________________________|________________________________|________________________________|\n")
.append("| | | |\n")
.append("| | | |\n")
.append("| " + Colors.ANSI_BRIGHT_BLACK + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locations.getJSONObject(0).getString("name") + Colors.ANSI_RESET + " | " + Colors.ANSI_GREEN + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| " + Colors.ANSI_BRIGHT_BLACK + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locationWald + Colors.ANSI_RESET + " | " + Colors.ANSI_GREEN + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| | | |\n")
.append("|________________________________|________________________________|________________________________|\n");
@ -78,7 +79,7 @@ public class MapCommand implements CommandAPI{
.append("|________________________________|________________________________|________________________________|\n")
.append("| | | |\n")
.append("| | | |\n")
.append("| " + Colors.ANSI_BLUE + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locations.getJSONObject(0).getString("name") + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| " + Colors.ANSI_BLUE + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locationWald + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| | | |\n")
.append("|________________________________|________________________________|________________________________|\n");
@ -94,7 +95,7 @@ public class MapCommand implements CommandAPI{
.append("|________________________________|________________________________|________________________________|\n")
.append("| | | |\n")
.append("| | | |\n")
.append("| " + Colors.ANSI_BRIGHT_BLACK + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locations.getJSONObject(0).getString("name") + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| " + Colors.ANSI_BRIGHT_BLACK + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locationWald + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| | | |\n")
.append("|________________________________|________________________________|________________________________|\n");
@ -110,7 +111,7 @@ public class MapCommand implements CommandAPI{
.append("|________________________________|________________________________|________________________________|\n")
.append("| | | |\n")
.append("| | | |\n")
.append("| " + Colors.ANSI_BRIGHT_BLACK + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locations.getJSONObject(0).getString("name") + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| " + Colors.ANSI_BRIGHT_BLACK + locationStrand + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locationWald + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locations.getJSONObject(3).getString("name") + Colors.ANSI_RESET + " |" + "\n")
.append("| | | |\n")
.append("|________________________________|________________________________|________________________________|\n");
}

Loading…
Cancel
Save