From 616bb737a3c7bdda829d4549195d433e8d3f2df1 Mon Sep 17 00:00:00 2001 From: Tanja Herche Date: Sun, 5 Feb 2023 17:55:54 +0100 Subject: [PATCH] refactoring: created String for integrated Location Winterland --- src/main/java/org/bitbiome/commands/MapCommand.java | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/main/java/org/bitbiome/commands/MapCommand.java b/src/main/java/org/bitbiome/commands/MapCommand.java index 559b2e9..25bd2e9 100644 --- a/src/main/java/org/bitbiome/commands/MapCommand.java +++ b/src/main/java/org/bitbiome/commands/MapCommand.java @@ -17,6 +17,7 @@ public class MapCommand implements CommandAPI{ JSONArray locations = travelEngine.getLocationList(); String locationWueste = locations.getJSONObject(5).getString("name"); String locationGruenland = locations.getJSONObject(4).getString("name"); + String locationWinterland = locations.getJSONObject(2).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) @@ -24,7 +25,7 @@ public class MapCommand implements CommandAPI{ .append(" __________________________________________________________________________________________________\n") .append("| | | |\n") .append("| | | |\n") - .append("| " + Colors.ANSI_BRIGHT_BLACK + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locations.getJSONObject(2).getString("name") + Colors.ANSI_RESET + " |" + "\n") + .append("| " + Colors.ANSI_BRIGHT_BLACK + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locationWinterland + Colors.ANSI_RESET + " |" + "\n") .append("| | | |\n") .append("|________________________________|________________________________|________________________________|\n") .append("| | | |\n") @@ -39,7 +40,7 @@ public class MapCommand implements CommandAPI{ .append(" __________________________________________________________________________________________________\n") .append("| | | |\n") .append("| | | |\n") - .append("| " + Colors.ANSI_BLUE + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locations.getJSONObject(2).getString("name") + Colors.ANSI_RESET + " |" + "\n") + .append("| " + Colors.ANSI_BLUE + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locationWinterland + Colors.ANSI_RESET + " |" + "\n") .append("| | | |\n") .append("|________________________________|________________________________|________________________________|\n") .append("| | | |\n") @@ -55,7 +56,7 @@ public class MapCommand implements CommandAPI{ .append(" __________________________________________________________________________________________________\n") .append("| | | |\n") .append("| | | |\n") - .append("| " + Colors.ANSI_BRIGHT_BLACK + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locations.getJSONObject(2).getString("name") + Colors.ANSI_RESET + " |" + "\n") + .append("| " + Colors.ANSI_BRIGHT_BLACK + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locationWinterland + Colors.ANSI_RESET + " |" + "\n") .append("| | | |\n") .append("|________________________________|________________________________|________________________________|\n") .append("| | | |\n") @@ -71,7 +72,7 @@ public class MapCommand implements CommandAPI{ .append(" __________________________________________________________________________________________________\n") .append("| | | |\n") .append("| | | |\n") - .append("| " + Colors.ANSI_GREEN + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locations.getJSONObject(2).getString("name") + Colors.ANSI_RESET + " |" + "\n") + .append("| " + Colors.ANSI_GREEN + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_BRIGHT_BLACK + locationWinterland + Colors.ANSI_RESET + " |" + "\n") .append("| | | |\n") .append("|________________________________|________________________________|________________________________|\n") .append("| | | |\n") @@ -87,7 +88,7 @@ public class MapCommand implements CommandAPI{ .append(" __________________________________________________________________________________________________\n") .append("| | | |\n") .append("| | | |\n") - .append("| " + Colors.ANSI_BLUE + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_GREEN + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locations.getJSONObject(2).getString("name") + Colors.ANSI_RESET + " |" + "\n") + .append("| " + Colors.ANSI_BLUE + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_GREEN + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locationWinterland + Colors.ANSI_RESET + " |" + "\n") .append("| | | |\n") .append("|________________________________|________________________________|________________________________|\n") .append("| | | |\n") @@ -103,7 +104,7 @@ public class MapCommand implements CommandAPI{ .append(" __________________________________________________________________________________________________\n") .append("| | | |\n") .append("| | | |\n") - .append("| " + Colors.ANSI_BRIGHT_BLACK + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_GREEN + locations.getJSONObject(2).getString("name") + Colors.ANSI_RESET + " |" + "\n") + .append("| " + Colors.ANSI_BRIGHT_BLACK + locationWueste + Colors.ANSI_RESET + " | " + Colors.ANSI_BLUE + locationGruenland + Colors.ANSI_RESET + " | " + Colors.ANSI_GREEN + locationWinterland + Colors.ANSI_RESET + " |" + "\n") .append("| | | |\n") .append("|________________________________|________________________________|________________________________|\n") .append("| | | |\n")