diff --git a/src/de/steamwar/bungeecore/SubserverSystem.java b/src/de/steamwar/bungeecore/SubserverSystem.java index 015393b..b0085f0 100644 --- a/src/de/steamwar/bungeecore/SubserverSystem.java +++ b/src/de/steamwar/bungeecore/SubserverSystem.java @@ -189,7 +189,7 @@ public class SubserverSystem { public static void sendPlayer(Subserver subserver, ProxiedPlayer player) { subserver.sendPlayer(player); if(!subserver.hasStarted() && FightInfoHandler.onLobby(player)) - new StartingServerPacket().send(player); + new StartingServerPacket(SteamwarUser.get(player.getUniqueId())).send(player); } private static boolean bauRunning(ProxiedPlayer p, UUID owner){ diff --git a/src/de/steamwar/bungeecore/comms/packets/StartingServerPacket.java b/src/de/steamwar/bungeecore/comms/packets/StartingServerPacket.java index b7058c2..1e5edf1 100644 --- a/src/de/steamwar/bungeecore/comms/packets/StartingServerPacket.java +++ b/src/de/steamwar/bungeecore/comms/packets/StartingServerPacket.java @@ -3,16 +3,23 @@ package de.steamwar.bungeecore.comms.packets; import com.google.common.io.ByteArrayDataOutput; import de.steamwar.bungeecore.comms.BungeePacket; import de.steamwar.bungeecore.comms.PacketIdManager; +import de.steamwar.bungeecore.sql.SteamwarUser; public class StartingServerPacket extends BungeePacket { + private final int user; + + public StartingServerPacket(SteamwarUser user) { + this.user = user.getId(); + } + @Override public int getId() { return PacketIdManager.STARTING_SERVER; } @Override - public void writeVars(ByteArrayDataOutput byteArrayDataOutput) { - //nothing to write + public void writeVars(ByteArrayDataOutput out) { + out.writeInt(user); } }