mirror of
https://github.com/SpigotMC/BungeeCord.git
synced 2025-01-26 01:21:31 +01:00
Forward even when no players are online.
This commit is contained in:
parent
4055139dcd
commit
36f5f33db0
@ -404,14 +404,13 @@ public class UserConnection extends GenericConnection implements ProxiedPlayer
|
|||||||
|
|
||||||
if (target.equals("ALL"))
|
if (target.equals("ALL"))
|
||||||
{
|
{
|
||||||
for (String s : BungeeCord.getInstance().getServers().keySet())
|
for (ServerInfo server : BungeeCord.getInstance().getServers().values())
|
||||||
{
|
{
|
||||||
Server server = BungeeCord.getInstance().getServer(s);
|
|
||||||
server.sendData("BungeeCord", b.toByteArray());
|
server.sendData("BungeeCord", b.toByteArray());
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
{
|
{
|
||||||
Server server = BungeeCord.getInstance().getServer(target);
|
ServerInfo server = BungeeCord.getInstance().getServerInfo(target);
|
||||||
if (server != null)
|
if (server != null)
|
||||||
{
|
{
|
||||||
server.sendData("BungeeCord", b.toByteArray());
|
server.sendData("BungeeCord", b.toByteArray());
|
||||||
@ -420,7 +419,7 @@ public class UserConnection extends GenericConnection implements ProxiedPlayer
|
|||||||
}
|
}
|
||||||
if (subChannel.equals("Connect"))
|
if (subChannel.equals("Connect"))
|
||||||
{
|
{
|
||||||
ServerInfo server = BungeeCord.getInstance().config.getServers().get(in.readUTF());
|
ServerInfo server = ProxyServer.getInstance().getServerInfo(in.readUTF());
|
||||||
if (server != null)
|
if (server != null)
|
||||||
{
|
{
|
||||||
connect(server);
|
connect(server);
|
||||||
@ -438,7 +437,7 @@ public class UserConnection extends GenericConnection implements ProxiedPlayer
|
|||||||
}
|
}
|
||||||
if (subChannel.equals("PlayerCount"))
|
if (subChannel.equals("PlayerCount"))
|
||||||
{
|
{
|
||||||
ServerInfo server = BungeeCord.getInstance().config.getServers().get(in.readUTF());
|
ServerInfo server = ProxyServer.getInstance().getServerInfo(in.readUTF());
|
||||||
if (server != null)
|
if (server != null)
|
||||||
{
|
{
|
||||||
ByteArrayOutputStream b = new ByteArrayOutputStream();
|
ByteArrayOutputStream b = new ByteArrayOutputStream();
|
||||||
@ -451,7 +450,7 @@ public class UserConnection extends GenericConnection implements ProxiedPlayer
|
|||||||
}
|
}
|
||||||
if (subChannel.equals("PlayerList"))
|
if (subChannel.equals("PlayerList"))
|
||||||
{
|
{
|
||||||
ServerInfo server = BungeeCord.getInstance().config.getServers().get(in.readUTF());
|
ServerInfo server = ProxyServer.getInstance().getServerInfo(in.readUTF());
|
||||||
if (server != null)
|
if (server != null)
|
||||||
{
|
{
|
||||||
ByteArrayOutputStream b = new ByteArrayOutputStream();
|
ByteArrayOutputStream b = new ByteArrayOutputStream();
|
||||||
|
Loading…
Reference in New Issue
Block a user