From 000ba6aee076b3ba9660c8a22f7713e2fef41f6f Mon Sep 17 00:00:00 2001 From: Lixfel Date: Thu, 12 Sep 2019 06:57:14 +0200 Subject: [PATCH] New Eventworldname --- src/de/steamwar/bungeecore/SubserverSystem.java | 3 ++- src/de/steamwar/bungeecore/commands/EventCommand.java | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/de/steamwar/bungeecore/SubserverSystem.java b/src/de/steamwar/bungeecore/SubserverSystem.java index 1ad45c2..f981f5a 100644 --- a/src/de/steamwar/bungeecore/SubserverSystem.java +++ b/src/de/steamwar/bungeecore/SubserverSystem.java @@ -1,5 +1,6 @@ package de.steamwar.bungeecore; +import de.steamwar.bungeecore.commands.EventCommand; import de.steamwar.bungeecore.sql.Bauwelt; import de.steamwar.bungeecore.sql.EventFight; import de.steamwar.bungeecore.sql.SteamwarUser; @@ -37,7 +38,7 @@ public class SubserverSystem { public static Subserver startEventArena(EventFight eventFight, String serverName){ int port = freePort(2500); return new Subserver(Servertype.ARENA, serverName, port, - MC_SCRIPT, "-a", eventFight.getSpielmodus().name(), serverName.replace(' ', '_'), Integer.toString(port), eventFight.getMap(), Integer.toString(eventFight.getFightID())); + MC_SCRIPT, "-a", eventFight.getSpielmodus().name(), serverName.replace(' ', '_') + eventFight.getStartTime().toLocalDateTime().format(EventCommand.TIME_FORMAT), Integer.toString(port), eventFight.getMap(), Integer.toString(eventFight.getFightID())); } public static void sendToBauServer(ProxiedPlayer p, UUID owner){ diff --git a/src/de/steamwar/bungeecore/commands/EventCommand.java b/src/de/steamwar/bungeecore/commands/EventCommand.java index 94a5e4c..f584bfd 100644 --- a/src/de/steamwar/bungeecore/commands/EventCommand.java +++ b/src/de/steamwar/bungeecore/commands/EventCommand.java @@ -18,8 +18,8 @@ import java.util.Set; public class EventCommand extends BasicCommand { - private static final DateTimeFormatter TIME_FORMAT = DateTimeFormatter.ofPattern("HH:mm"); - public static final DateTimeFormatter DATE_FORMAT = DateTimeFormatter.ofPattern("dd.MM."); + public static final DateTimeFormatter TIME_FORMAT = DateTimeFormatter.ofPattern("HH:mm"); + static final DateTimeFormatter DATE_FORMAT = DateTimeFormatter.ofPattern("dd.MM."); public EventCommand() { super("event", "");