#2474: Allow ALL in the Message channel

This commit is contained in:
maol3 2018-07-21 10:56:49 +02:00 committed by md_5
parent 7ce9ae50e7
commit 95ed7a5775

View File

@ -391,10 +391,21 @@ public class DownstreamBridge extends PacketHandler
}
if ( subChannel.equals( "Message" ) )
{
ProxiedPlayer target = bungee.getPlayer( in.readUTF() );
if ( target != null )
String target = in.readUTF();
String message = in.readUTF();
if ( target.equals( "ALL" ) )
{
target.sendMessage( in.readUTF() );
for ( ProxiedPlayer player : bungee.getPlayers() )
{
player.sendMessage( message );
}
} else
{
ProxiedPlayer player = bungee.getPlayer( target );
if ( player != null )
{
player.sendMessage( message );
}
}
}
if ( subChannel.equals( "GetServer" ) )