Only force remove the player from 1.8 client's tab list

This commit is contained in:
Thinkofdeath 2015-05-10 22:51:14 +01:00
parent 585ab4f453
commit 93959cab4b

View File

@ -13,6 +13,7 @@ import net.md_5.bungee.api.event.TabCompleteEvent;
import net.md_5.bungee.netty.ChannelWrapper; import net.md_5.bungee.netty.ChannelWrapper;
import net.md_5.bungee.netty.PacketHandler; import net.md_5.bungee.netty.PacketHandler;
import net.md_5.bungee.protocol.PacketWrapper; import net.md_5.bungee.protocol.PacketWrapper;
import net.md_5.bungee.protocol.ProtocolConstants;
import net.md_5.bungee.protocol.packet.KeepAlive; import net.md_5.bungee.protocol.packet.KeepAlive;
import net.md_5.bungee.protocol.packet.Chat; import net.md_5.bungee.protocol.packet.Chat;
import net.md_5.bungee.protocol.packet.PlayerListItem; import net.md_5.bungee.protocol.packet.PlayerListItem;
@ -73,7 +74,10 @@ public class UpstreamBridge extends PacketHandler
} ); } );
for ( ProxiedPlayer player : con.getServer().getInfo().getPlayers() ) for ( ProxiedPlayer player : con.getServer().getInfo().getPlayers() )
{ {
player.unsafe().sendPacket( packet ); if ( player.getPendingConnection().getVersion() >= ProtocolConstants.MINECRAFT_1_8 )
{
player.unsafe().sendPacket( packet );
}
} }
con.getServer().disconnect( "Quitting" ); con.getServer().disconnect( "Quitting" );
} }