From b2fe26b3575ab49291c8963f41a9117fd3e4cd79 Mon Sep 17 00:00:00 2001 From: LAX1DUDE Date: Thu, 21 Jul 2022 21:26:26 -0700 Subject: [PATCH] removed unused imports --- .../main/java/net/md_5/bungee/BungeeCord.java | 142 +++++++++--------- .../net/md_5/bungee/BungeeServerInfo.java | 46 +++--- .../java/net/md_5/bungee/EncryptionUtil.java | 24 +-- .../java/net/md_5/bungee/PacketConstants.java | 4 +- .../net/md_5/bungee/ServerConnection.java | 9 +- .../java/net/md_5/bungee/ServerConnector.java | 76 +++++----- .../java/net/md_5/bungee/UserConnection.java | 69 ++++----- .../src/main/java/net/md_5/bungee/Util.java | 3 +- .../java/net/md_5/bungee/api/ProxyServer.java | 16 +- .../md_5/bungee/api/config/ListenerInfo.java | 5 +- .../md_5/bungee/api/config/ServerInfo.java | 7 +- .../bungee/api/connection/Connection.java | 3 +- .../api/connection/PendingConnection.java | 3 +- .../bungee/api/connection/ProxiedPlayer.java | 6 +- .../net/md_5/bungee/api/event/AsyncEvent.java | 13 +- .../api/event/PermissionCheckEvent.java | 1 + .../api/event/PlayerDisconnectEvent.java | 1 + .../bungee/api/event/PluginMessageEvent.java | 1 + .../md_5/bungee/api/event/PostLoginEvent.java | 1 + .../md_5/bungee/api/event/ProxyPingEvent.java | 1 + .../api/event/ServerConnectedEvent.java | 3 +- .../bungee/api/event/ServerSwitchEvent.java | 1 + .../md_5/bungee/api/event/TargetedEvent.java | 1 + .../net/md_5/bungee/api/plugin/Command.java | 4 +- .../net/md_5/bungee/api/plugin/Plugin.java | 3 +- .../bungee/api/plugin/PluginClassloader.java | 5 +- .../bungee/api/plugin/PluginDescription.java | 2 +- .../md_5/bungee/api/plugin/PluginLogger.java | 3 +- .../md_5/bungee/api/plugin/PluginManager.java | 43 +++--- .../bungee/api/scheduler/ScheduledTask.java | 1 + .../bungee/api/scheduler/TaskScheduler.java | 1 + .../net/md_5/bungee/api/score/Scoreboard.java | 7 +- .../java/net/md_5/bungee/api/score/Team.java | 4 +- .../net/md_5/bungee/command/CommandAlert.java | 2 +- .../md_5/bungee/command/CommandBungee.java | 2 +- .../net/md_5/bungee/command/CommandFind.java | 4 +- .../bungee/command/CommandGlobalBanIP.java | 1 - .../bungee/command/CommandGlobalListBan.java | 2 - .../net/md_5/bungee/command/CommandIP.java | 5 +- .../net/md_5/bungee/command/CommandList.java | 17 +-- .../net/md_5/bungee/command/CommandPerms.java | 9 +- .../md_5/bungee/command/CommandReload.java | 2 +- .../net/md_5/bungee/command/CommandSend.java | 7 +- .../md_5/bungee/command/CommandServer.java | 8 +- .../bungee/command/ConsoleCommandSender.java | 5 +- .../net/md_5/bungee/config/Configuration.java | 18 ++- .../net/md_5/bungee/config/YamlConfig.java | 49 +++--- .../bungee/connection/DownstreamBridge.java | 48 +++--- .../bungee/connection/InitialHandler.java | 82 +++++----- .../md_5/bungee/connection/PingHandler.java | 7 +- .../bungee/connection/UpstreamBridge.java | 26 ++-- .../bungee/eaglercraft/PluginEaglerAuth.java | 3 - .../bungee/eaglercraft/PluginEaglerVoice.java | 21 ++- .../java/net/md_5/bungee/event/EventBus.java | 19 ++- .../net/md_5/bungee/event/EventHandler.java | 5 +- .../net/md_5/bungee/log/BungeeLogger.java | 6 +- .../net/md_5/bungee/log/ColouredWriter.java | 6 +- .../net/md_5/bungee/log/ConciseFormatter.java | 5 +- .../net/md_5/bungee/log/LogDispatcher.java | 3 +- .../md_5/bungee/log/LoggingOutputStream.java | 2 +- .../net/md_5/bungee/netty/ChannelWrapper.java | 2 +- .../net/md_5/bungee/netty/CipherBase.java | 8 +- .../net/md_5/bungee/netty/CipherDecoder.java | 5 +- .../net/md_5/bungee/netty/CipherEncoder.java | 3 +- .../bungee/netty/DefinedPacketEncoder.java | 4 +- .../net/md_5/bungee/netty/HandlerBoss.java | 18 +-- .../net/md_5/bungee/netty/PacketDecoder.java | 7 +- .../net/md_5/bungee/netty/PipelineUtils.java | 28 ++-- .../java/net/md_5/bungee/protocol/Forge.java | 4 +- .../net/md_5/bungee/protocol/Protocol.java | 3 +- .../net/md_5/bungee/protocol/Vanilla.java | 41 ++--- .../bungee/protocol/packet/DefinedPacket.java | 1 + .../bungee/protocol/packet/PacketD1Team.java | 1 + .../packet/PacketFAPluginMessage.java | 1 + .../packet/PacketFCEncryptionResponse.java | 1 + .../packet/PacketFDEncryptionRequest.java | 1 + .../protocol/packet/forge/Forge1Login.java | 2 +- .../bungee/protocol/skip/PacketReader.java | 5 +- .../reconnect/AbstractReconnectManager.java | 5 +- .../bungee/reconnect/SQLReconnectHandler.java | 9 +- .../bungee/scheduler/BungeeScheduler.java | 26 ++-- .../net/md_5/bungee/scheduler/BungeeTask.java | 3 +- .../bungee/scheduler/BungeeThreadPool.java | 9 +- .../main/java/net/md_5/bungee/tab/Custom.java | 12 +- .../main/java/net/md_5/bungee/tab/Global.java | 6 +- .../java/net/md_5/bungee/tab/GlobalPing.java | 3 +- .../net/md_5/bungee/tab/ServerUnique.java | 7 +- .../md_5/bungee/util/CaseInsensitiveMap.java | 3 +- .../md_5/bungee/util/CaseInsensitiveSet.java | 3 +- .../net/lax1dude/eaglercraft/BaseNCodec.java | 2 - .../lax1dude/eaglercraft/EarlyLoadScreen.java | 60 +++++++- .../eaglercraft/TextureTerrainMap.java | 2 - .../eaglercraft/WebsocketNetworkManager.java | 2 +- .../eaglercraft/glemu/EaglerAdapterGL30.java | 1 - .../eaglercraft/glemu/EffectPipeline.java | 87 ++++++++++- .../eaglercraft/glemu/EffectPipelineFXAA.java | 93 +++++++++++- .../glemu/FixedFunctionShader.java | 41 ++++- .../eaglercraft/glemu/HighPolyMesh.java | 21 ++- .../java/net/minecraft/client/Minecraft.java | 66 +++++++- .../net/minecraft/src/ActiveRenderInfo.java | 1 - .../minecraft/src/ContainerEnchantment.java | 2 - .../net/minecraft/src/CreativeCrafting.java | 1 + .../java/net/minecraft/src/EntityBoat.java | 4 - .../minecraft/src/EntityLightningBolt.java | 2 - .../net/minecraft/src/EntityMinecart.java | 4 - .../java/net/minecraft/src/EntityPlayer.java | 1 - .../java/net/minecraft/src/EntityPotion.java | 5 - .../net/minecraft/src/EntityRenderer.java | 3 +- .../net/minecraft/src/EntityThrowable.java | 4 - .../java/net/minecraft/src/EntityWitch.java | 3 - .../java/net/minecraft/src/GLAllocation.java | 1 - .../net/minecraft/src/GuiAchievement.java | 2 +- .../net/minecraft/src/GuiBeaconButton.java | 2 +- .../java/net/minecraft/src/GuiButton.java | 2 +- .../net/minecraft/src/GuiButtonLanguage.java | 2 +- .../net/minecraft/src/GuiButtonMerchant.java | 2 +- .../net/minecraft/src/GuiButtonNextPage.java | 2 +- .../java/net/minecraft/src/GuiContainer.java | 3 +- .../java/net/minecraft/src/GuiIngame.java | 2 +- .../java/net/minecraft/src/GuiInventory.java | 3 +- .../java/net/minecraft/src/GuiNewChat.java | 1 - .../java/net/minecraft/src/GuiParticle.java | 3 +- .../java/net/minecraft/src/GuiRepair.java | 3 +- .../java/net/minecraft/src/GuiScreen.java | 3 +- src/main/java/net/minecraft/src/GuiSlot.java | 3 +- .../java/net/minecraft/src/GuiSlotServer.java | 2 +- .../java/net/minecraft/src/GuiTextField.java | 1 - .../java/net/minecraft/src/ItemRenderer.java | 3 +- .../minecraft/src/LoadingScreenRenderer.java | 2 +- .../java/net/minecraft/src/ModelRenderer.java | 1 - .../net/minecraft/src/NetClientHandler.java | 6 +- src/main/java/net/minecraft/src/Packet.java | 1 - .../java/net/minecraft/src/RenderBlocks.java | 1 - .../minecraft/src/RenderEnchantmentTable.java | 1 - .../net/minecraft/src/RenderEndPortal.java | 3 +- .../java/net/minecraft/src/RenderEngine.java | 6 +- .../java/net/minecraft/src/RenderFish.java | 3 +- .../java/net/minecraft/src/RenderGlobal.java | 3 +- .../net/minecraft/src/RenderIronGolem.java | 1 - .../java/net/minecraft/src/RenderItem.java | 2 +- .../java/net/minecraft/src/RenderLiving.java | 8 +- .../net/minecraft/src/RenderMagmaCube.java | 1 - .../net/minecraft/src/RenderMinecart.java | 1 - .../java/net/minecraft/src/RenderPlayer.java | 4 +- .../net/minecraft/src/StringTranslate.java | 1 - .../net/minecraft/src/TexturePackList.java | 1 + .../net/minecraft/src/TextureStitched.java | 1 - .../net/minecraft/src/TileEntityBeacon.java | 3 - .../src/TileEntityBeaconRenderer.java | 2 - .../net/minecraft/src/TileEntityChest.java | 3 - .../src/TileEntityChestRenderer.java | 1 - .../src/TileEntityEnderChestRenderer.java | 1 - .../src/TileEntityRendererPiston.java | 2 +- src/main/java/org/json/XML.java | 1 - .../adapter/EaglerAdapterImpl2.java | 134 ++++++++++++++++- 155 files changed, 1078 insertions(+), 655 deletions(-) diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/BungeeCord.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/BungeeCord.java index 3ec27eb..4623187 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/BungeeCord.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/BungeeCord.java @@ -4,48 +4,71 @@ package net.md_5.bungee; -import net.md_5.bungee.tab.Custom; -import net.md_5.bungee.api.tab.CustomTabList; -import net.md_5.bungee.protocol.packet.Packet3Chat; - +import java.io.File; +import java.io.IOException; +import java.io.PrintStream; import java.net.InetAddress; import java.net.InetSocketAddress; import java.net.ServerSocket; - -import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; -import java.util.Collections; -import net.md_5.bungee.api.config.ServerInfo; -import net.md_5.bungee.api.connection.ProxiedPlayer; -import java.util.MissingResourceException; -import net.md_5.bungee.protocol.packet.DefinedPacket; -import io.netty.channel.ChannelException; -import io.netty.util.concurrent.GenericFutureListener; import java.net.SocketAddress; -import io.netty.channel.EventLoopGroup; -import io.netty.channel.ChannelHandler; -import io.netty.util.AttributeKey; -import net.md_5.bungee.netty.PipelineUtils; -import io.netty.channel.socket.nio.NioServerSocketChannel; +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.Map; +import java.util.MissingResourceException; +import java.util.ResourceBundle; +import java.util.Timer; +import java.util.TimerTask; +import java.util.concurrent.ScheduledThreadPoolExecutor; +import java.util.concurrent.TimeUnit; +import java.util.concurrent.locks.ReadWriteLock; +import java.util.concurrent.locks.ReentrantReadWriteLock; +import java.util.logging.Level; +import java.util.logging.Logger; + +import org.fusesource.jansi.AnsiConsole; + +import com.google.common.io.ByteStreams; +import com.google.common.util.concurrent.ThreadFactoryBuilder; + import io.netty.bootstrap.ServerBootstrap; +import io.netty.channel.Channel; +import io.netty.channel.ChannelException; import io.netty.channel.ChannelFuture; import io.netty.channel.ChannelFutureListener; -import net.md_5.bungee.api.config.ListenerInfo; -import java.util.TimerTask; -import net.md_5.bungee.reconnect.SQLReconnectHandler; +import io.netty.channel.ChannelHandler; +import io.netty.channel.EventLoopGroup; +import io.netty.channel.MultithreadEventLoopGroup; +import io.netty.channel.nio.NioEventLoopGroup; +import io.netty.channel.socket.nio.NioServerSocketChannel; +import io.netty.util.AttributeKey; +import io.netty.util.concurrent.GenericFutureListener; +import jline.UnsupportedTerminal; +import jline.console.ConsoleReader; +import jline.internal.Log; import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.CommandSender; -import net.md_5.bungee.command.ConsoleCommandSender; -import java.util.concurrent.TimeUnit; -import java.util.ArrayList; -import java.io.IOException; -import jline.UnsupportedTerminal; -import net.md_5.bungee.log.LoggingOutputStream; -import java.util.logging.Level; -import net.md_5.bungee.log.BungeeLogger; -import org.fusesource.jansi.AnsiConsole; -import jline.internal.Log; -import java.io.PrintStream; -import com.google.common.io.ByteStreams; +import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.ReconnectHandler; +import net.md_5.bungee.api.config.ConfigurationAdapter; +import net.md_5.bungee.api.config.ListenerInfo; +import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.api.connection.ProxiedPlayer; +import net.md_5.bungee.api.plugin.Command; +import net.md_5.bungee.api.plugin.Plugin; +import net.md_5.bungee.api.plugin.PluginManager; +import net.md_5.bungee.api.scheduler.TaskScheduler; +import net.md_5.bungee.api.tab.CustomTabList; +import net.md_5.bungee.command.CommandAlert; +import net.md_5.bungee.command.CommandBungee; +import net.md_5.bungee.command.CommandClearRatelimit; +import net.md_5.bungee.command.CommandConfirmCode; +import net.md_5.bungee.command.CommandDomain; +import net.md_5.bungee.command.CommandDomainBlock; +import net.md_5.bungee.command.CommandDomainBlockDomain; +import net.md_5.bungee.command.CommandDomainUnblock; +import net.md_5.bungee.command.CommandEnd; import net.md_5.bungee.command.CommandFind; import net.md_5.bungee.command.CommandGlobalBan; import net.md_5.bungee.command.CommandGlobalBanIP; @@ -55,54 +78,31 @@ import net.md_5.bungee.command.CommandGlobalBanWildcard; import net.md_5.bungee.command.CommandGlobalCheckBan; import net.md_5.bungee.command.CommandGlobalListBan; import net.md_5.bungee.command.CommandGlobalUnban; -import net.md_5.bungee.command.CommandSend; -import net.md_5.bungee.command.CommandPerms; -import net.md_5.bungee.command.CommandBungee; -import net.md_5.bungee.command.CommandClearRatelimit; -import net.md_5.bungee.command.CommandConfirmCode; -import net.md_5.bungee.command.CommandDomain; -import net.md_5.bungee.command.CommandDomainBlock; -import net.md_5.bungee.command.CommandDomainBlockDomain; -import net.md_5.bungee.command.CommandDomainUnblock; -import net.md_5.bungee.command.CommandAlert; import net.md_5.bungee.command.CommandIP; -import net.md_5.bungee.command.CommandServer; import net.md_5.bungee.command.CommandList; -import net.md_5.bungee.command.CommandEnd; -import net.md_5.bungee.api.plugin.Command; -import net.md_5.bungee.api.plugin.Plugin; +import net.md_5.bungee.command.CommandPerms; import net.md_5.bungee.command.CommandReload; -import net.md_5.bungee.scheduler.BungeeScheduler; +import net.md_5.bungee.command.CommandSend; +import net.md_5.bungee.command.CommandServer; +import net.md_5.bungee.command.ConsoleCommandSender; +import net.md_5.bungee.config.Configuration; import net.md_5.bungee.config.YamlConfig; import net.md_5.bungee.eaglercraft.BanList; import net.md_5.bungee.eaglercraft.DomainBlacklist; import net.md_5.bungee.eaglercraft.PluginEaglerSkins; import net.md_5.bungee.eaglercraft.PluginEaglerVoice; import net.md_5.bungee.eaglercraft.WebSocketListener; - -import java.util.concurrent.locks.ReentrantReadWriteLock; -import net.md_5.bungee.util.CaseInsensitiveMap; -import java.util.HashSet; -import io.netty.channel.nio.NioEventLoopGroup; +import net.md_5.bungee.log.BungeeLogger; +import net.md_5.bungee.log.LoggingOutputStream; +import net.md_5.bungee.netty.PipelineUtils; +import net.md_5.bungee.protocol.packet.DefinedPacket; +import net.md_5.bungee.protocol.packet.Packet3Chat; +import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; +import net.md_5.bungee.reconnect.SQLReconnectHandler; +import net.md_5.bungee.scheduler.BungeeScheduler; import net.md_5.bungee.scheduler.BungeeThreadPool; -import com.google.common.util.concurrent.ThreadFactoryBuilder; -import java.util.logging.Logger; -import jline.console.ConsoleReader; -import net.md_5.bungee.api.scheduler.TaskScheduler; -import java.io.File; -import net.md_5.bungee.api.config.ConfigurationAdapter; -import net.md_5.bungee.api.ReconnectHandler; -import net.md_5.bungee.api.plugin.PluginManager; -import java.util.concurrent.locks.ReadWriteLock; -import java.util.Map; -import io.netty.channel.Channel; -import java.util.Collection; -import java.util.Timer; -import io.netty.channel.MultithreadEventLoopGroup; -import java.util.concurrent.ScheduledThreadPoolExecutor; -import java.util.ResourceBundle; -import net.md_5.bungee.config.Configuration; -import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.tab.Custom; +import net.md_5.bungee.util.CaseInsensitiveMap; public class BungeeCord extends ProxyServer { public volatile boolean isRunning; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/BungeeServerInfo.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/BungeeServerInfo.java index 84ee4b9..d0e9628 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/BungeeServerInfo.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/BungeeServerInfo.java @@ -5,36 +5,36 @@ package net.md_5.bungee; import java.beans.ConstructorProperties; -import java.util.LinkedList; -import java.util.ArrayList; -import io.netty.util.concurrent.GenericFutureListener; +import java.net.InetSocketAddress; import java.net.SocketAddress; -import io.netty.channel.ChannelOption; -import io.netty.channel.ChannelHandler; -import net.md_5.bungee.netty.PipelineUtils; -import io.netty.channel.EventLoopGroup; -import io.netty.channel.socket.nio.NioSocketChannel; +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.LinkedList; +import java.util.Objects; +import java.util.Queue; + +import com.google.common.base.Preconditions; + import io.netty.bootstrap.Bootstrap; -import io.netty.util.concurrent.Future; -import net.md_5.bungee.netty.PacketHandler; -import net.md_5.bungee.connection.PingHandler; -import net.md_5.bungee.netty.HandlerBoss; import io.netty.channel.ChannelFuture; import io.netty.channel.ChannelFutureListener; -import net.md_5.bungee.api.ServerPing; +import io.netty.channel.ChannelHandler; +import io.netty.channel.ChannelOption; +import io.netty.channel.EventLoopGroup; +import io.netty.channel.socket.nio.NioSocketChannel; +import io.netty.util.concurrent.GenericFutureListener; import net.md_5.bungee.api.Callback; -import net.md_5.bungee.api.connection.Server; -import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; -import java.util.Objects; -import com.google.common.base.Preconditions; import net.md_5.bungee.api.CommandSender; -import java.util.Collections; -import net.md_5.bungee.protocol.packet.DefinedPacket; -import java.util.Queue; -import net.md_5.bungee.api.connection.ProxiedPlayer; -import java.util.Collection; -import java.net.InetSocketAddress; +import net.md_5.bungee.api.ServerPing; import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.api.connection.ProxiedPlayer; +import net.md_5.bungee.api.connection.Server; +import net.md_5.bungee.connection.PingHandler; +import net.md_5.bungee.netty.HandlerBoss; +import net.md_5.bungee.netty.PipelineUtils; +import net.md_5.bungee.protocol.packet.DefinedPacket; +import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; public class BungeeServerInfo implements ServerInfo { private final String name; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/EncryptionUtil.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/EncryptionUtil.java index 3f0ade9..2712509 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/EncryptionUtil.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/EncryptionUtil.java @@ -4,22 +4,24 @@ package net.md_5.bungee; -import java.security.NoSuchAlgorithmException; -import java.security.KeyPairGenerator; -import java.security.spec.X509EncodedKeySpec; -import java.security.KeyFactory; -import java.security.PublicKey; -import javax.crypto.spec.IvParameterSpec; import java.security.GeneralSecurityException; -import javax.crypto.spec.SecretKeySpec; -import java.util.Arrays; import java.security.Key; +import java.security.KeyFactory; +import java.security.KeyPair; +import java.security.KeyPairGenerator; +import java.security.NoSuchAlgorithmException; +import java.security.PublicKey; +import java.security.spec.X509EncodedKeySpec; +import java.util.Arrays; +import java.util.Random; + import javax.crypto.Cipher; +import javax.crypto.SecretKey; +import javax.crypto.spec.IvParameterSpec; +import javax.crypto.spec.SecretKeySpec; + import net.md_5.bungee.protocol.packet.PacketFCEncryptionResponse; import net.md_5.bungee.protocol.packet.PacketFDEncryptionRequest; -import javax.crypto.SecretKey; -import java.security.KeyPair; -import java.util.Random; public class EncryptionUtil { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/PacketConstants.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/PacketConstants.java index 1bfe72f..16fd2e0 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/PacketConstants.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/PacketConstants.java @@ -4,9 +4,9 @@ package net.md_5.bungee; -import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; -import net.md_5.bungee.protocol.packet.PacketCDClientStatus; import net.md_5.bungee.protocol.packet.Packet9Respawn; +import net.md_5.bungee.protocol.packet.PacketCDClientStatus; +import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; public class PacketConstants { public static final Packet9Respawn DIM1_SWITCH; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/ServerConnection.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/ServerConnection.java index 9a8f52b..95f2089 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/ServerConnection.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/ServerConnection.java @@ -7,12 +7,13 @@ package net.md_5.bungee; import java.beans.ConstructorProperties; import java.net.InetSocketAddress; import java.util.concurrent.TimeUnit; -import net.md_5.bungee.protocol.packet.PacketFFKick; + +import net.md_5.bungee.api.connection.Connection; +import net.md_5.bungee.api.connection.Server; +import net.md_5.bungee.netty.ChannelWrapper; import net.md_5.bungee.protocol.packet.DefinedPacket; import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; -import net.md_5.bungee.api.connection.Connection; -import net.md_5.bungee.netty.ChannelWrapper; -import net.md_5.bungee.api.connection.Server; +import net.md_5.bungee.protocol.packet.PacketFFKick; public class ServerConnection implements Server { private final ChannelWrapper ch; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/ServerConnector.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/ServerConnector.java index 05d1830..a24a805 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/ServerConnector.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/ServerConnector.java @@ -5,50 +5,48 @@ package net.md_5.bungee; import java.beans.ConstructorProperties; -import com.google.common.io.ByteArrayDataInput; -import net.md_5.bungee.protocol.Protocol; -import net.md_5.bungee.api.config.ServerInfo; -import net.md_5.bungee.api.event.ServerKickEvent; -import java.util.Objects; -import net.md_5.bungee.protocol.packet.PacketFFKick; -import net.md_5.bungee.netty.CipherDecoder; -import javax.crypto.Cipher; import java.security.PublicKey; -import io.netty.channel.ChannelHandler; -import net.md_5.bungee.netty.CipherEncoder; -import net.md_5.bungee.netty.PipelineUtils; -import net.md_5.bungee.protocol.packet.PacketFCEncryptionResponse; -import java.security.Key; -import net.md_5.bungee.protocol.packet.PacketFDEncryptionRequest; -import net.md_5.bungee.api.score.Scoreboard; -import java.util.Iterator; +import java.util.Objects; import java.util.Queue; -import net.md_5.bungee.connection.CancelSendSignal; -import net.md_5.bungee.api.event.ServerSwitchEvent; -import net.md_5.bungee.connection.DownstreamBridge; -import net.md_5.bungee.netty.HandlerBoss; -import net.md_5.bungee.protocol.packet.Packet9Respawn; -import net.md_5.bungee.protocol.packet.PacketD1Team; -import net.md_5.bungee.api.score.Team; -import net.md_5.bungee.protocol.packet.PacketCEScoreboardObjective; -import net.md_5.bungee.api.score.Objective; -import net.md_5.bungee.protocol.packet.DefinedPacket; -import net.md_5.bungee.protocol.packet.forge.Forge1Login; -import net.md_5.bungee.protocol.Forge; -import net.md_5.bungee.netty.PacketDecoder; -import net.md_5.bungee.api.connection.Server; -import net.md_5.bungee.api.connection.ProxiedPlayer; -import net.md_5.bungee.api.event.ServerConnectedEvent; -import com.google.common.base.Preconditions; -import net.md_5.bungee.protocol.packet.Packet1Login; -import com.google.common.io.ByteArrayDataOutput; -import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; -import com.google.common.io.ByteStreams; -import net.md_5.bungee.api.ChatColor; + +import javax.crypto.Cipher; import javax.crypto.SecretKey; -import net.md_5.bungee.netty.ChannelWrapper; + +import com.google.common.base.Preconditions; +import com.google.common.io.ByteArrayDataInput; +import com.google.common.io.ByteArrayDataOutput; +import com.google.common.io.ByteStreams; + +import io.netty.channel.ChannelHandler; +import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.api.event.ServerConnectedEvent; +import net.md_5.bungee.api.event.ServerKickEvent; +import net.md_5.bungee.api.event.ServerSwitchEvent; +import net.md_5.bungee.api.score.Objective; +import net.md_5.bungee.api.score.Scoreboard; +import net.md_5.bungee.api.score.Team; +import net.md_5.bungee.connection.CancelSendSignal; +import net.md_5.bungee.connection.DownstreamBridge; +import net.md_5.bungee.netty.ChannelWrapper; +import net.md_5.bungee.netty.CipherDecoder; +import net.md_5.bungee.netty.CipherEncoder; +import net.md_5.bungee.netty.HandlerBoss; +import net.md_5.bungee.netty.PacketDecoder; import net.md_5.bungee.netty.PacketHandler; +import net.md_5.bungee.netty.PipelineUtils; +import net.md_5.bungee.protocol.Forge; +import net.md_5.bungee.protocol.packet.DefinedPacket; +import net.md_5.bungee.protocol.packet.Packet1Login; +import net.md_5.bungee.protocol.packet.Packet9Respawn; +import net.md_5.bungee.protocol.packet.PacketCEScoreboardObjective; +import net.md_5.bungee.protocol.packet.PacketD1Team; +import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; +import net.md_5.bungee.protocol.packet.PacketFCEncryptionResponse; +import net.md_5.bungee.protocol.packet.PacketFDEncryptionRequest; +import net.md_5.bungee.protocol.packet.PacketFFKick; +import net.md_5.bungee.protocol.packet.forge.Forge1Login; public class ServerConnector extends PacketHandler { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/UserConnection.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/UserConnection.java index 25651d9..1a550c9 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/UserConnection.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/UserConnection.java @@ -5,52 +5,49 @@ package net.md_5.bungee; import java.beans.ConstructorProperties; -import net.md_5.bungee.util.CaseInsensitiveSet; -import java.util.HashSet; -import net.md_5.bungee.api.config.TexturePackInfo; -import net.md_5.bungee.api.event.PermissionCheckEvent; -import java.util.Collections; import java.net.InetSocketAddress; -import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; -import net.md_5.bungee.protocol.packet.Packet3Chat; -import net.md_5.bungee.protocol.packet.PacketFFKick; -import java.util.logging.Level; -import io.netty.util.concurrent.GenericFutureListener; -import io.netty.util.internal.PlatformDependent; import java.net.SocketAddress; -import io.netty.channel.ChannelOption; -import io.netty.channel.ChannelHandler; -import io.netty.channel.EventLoopGroup; -import io.netty.channel.socket.nio.NioSocketChannel; -import io.netty.bootstrap.Bootstrap; -import io.netty.util.concurrent.Future; -import io.netty.channel.ChannelFuture; -import io.netty.channel.ChannelFutureListener; -import net.md_5.bungee.netty.PacketHandler; -import net.md_5.bungee.netty.HandlerBoss; -import net.md_5.bungee.netty.PipelineUtils; -import io.netty.channel.Channel; -import io.netty.channel.ChannelInitializer; -import net.md_5.bungee.api.ChatColor; +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.Map; import java.util.Objects; import java.util.WeakHashMap; +import java.util.logging.Level; -import net.md_5.bungee.api.event.ServerConnectEvent; -import net.md_5.bungee.protocol.packet.DefinedPacket; import com.google.common.base.Preconditions; -import java.util.Iterator; -import java.util.Map; -import net.md_5.bungee.api.connection.Connection; -import net.md_5.bungee.api.score.Scoreboard; -import net.md_5.bungee.protocol.packet.PacketCCSettings; -import net.md_5.bungee.api.tab.TabListHandler; +import io.netty.bootstrap.Bootstrap; +import io.netty.channel.Channel; +import io.netty.channel.ChannelFuture; +import io.netty.channel.ChannelFutureListener; +import io.netty.channel.ChannelHandler; +import io.netty.channel.ChannelInitializer; +import io.netty.channel.ChannelOption; +import io.netty.channel.EventLoopGroup; +import io.netty.channel.socket.nio.NioSocketChannel; +import io.netty.util.concurrent.GenericFutureListener; +import io.netty.util.internal.PlatformDependent; +import net.md_5.bungee.api.ChatColor; +import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.config.ServerInfo; -import java.util.Collection; +import net.md_5.bungee.api.config.TexturePackInfo; +import net.md_5.bungee.api.connection.Connection; +import net.md_5.bungee.api.connection.ProxiedPlayer; +import net.md_5.bungee.api.event.PermissionCheckEvent; +import net.md_5.bungee.api.event.ServerConnectEvent; +import net.md_5.bungee.api.score.Scoreboard; +import net.md_5.bungee.api.tab.TabListHandler; import net.md_5.bungee.connection.InitialHandler; import net.md_5.bungee.netty.ChannelWrapper; -import net.md_5.bungee.api.ProxyServer; -import net.md_5.bungee.api.connection.ProxiedPlayer; +import net.md_5.bungee.netty.HandlerBoss; +import net.md_5.bungee.netty.PipelineUtils; +import net.md_5.bungee.protocol.packet.DefinedPacket; +import net.md_5.bungee.protocol.packet.Packet3Chat; +import net.md_5.bungee.protocol.packet.PacketCCSettings; +import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; +import net.md_5.bungee.protocol.packet.PacketFFKick; +import net.md_5.bungee.util.CaseInsensitiveSet; public final class UserConnection implements ProxiedPlayer { private final ProxyServer bungee; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/Util.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/Util.java index 4d8e43f..85a36c3 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/Util.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/Util.java @@ -4,9 +4,8 @@ package net.md_5.bungee; -import java.util.Iterator; -import java.util.Collection; import java.net.InetSocketAddress; +import java.util.Collection; public class Util { private static final int DEFAULT_PORT = 25565; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/ProxyServer.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/ProxyServer.java index 493de3f..2d7b7ff 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/ProxyServer.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/ProxyServer.java @@ -4,19 +4,21 @@ package net.md_5.bungee.api; -import net.md_5.bungee.api.tab.CustomTabList; -import net.md_5.bungee.api.scheduler.TaskScheduler; import java.io.File; import java.net.InetSocketAddress; -import net.md_5.bungee.api.config.ConfigurationAdapter; -import net.md_5.bungee.api.plugin.PluginManager; -import net.md_5.bungee.api.config.ServerInfo; -import java.util.Map; -import net.md_5.bungee.api.connection.ProxiedPlayer; import java.util.Collection; +import java.util.Map; import java.util.logging.Logger; + import com.google.common.base.Preconditions; +import net.md_5.bungee.api.config.ConfigurationAdapter; +import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.api.connection.ProxiedPlayer; +import net.md_5.bungee.api.plugin.PluginManager; +import net.md_5.bungee.api.scheduler.TaskScheduler; +import net.md_5.bungee.api.tab.CustomTabList; + public abstract class ProxyServer { private static ProxyServer instance; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/config/ListenerInfo.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/config/ListenerInfo.java index 1587d72..4750c43 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/config/ListenerInfo.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/config/ListenerInfo.java @@ -5,14 +5,13 @@ package net.md_5.bungee.api.config; import java.io.File; +import java.net.InetSocketAddress; +import java.util.Map; import net.md_5.bungee.api.ServerIcon; import net.md_5.bungee.api.tab.TabListHandler; import net.md_5.bungee.eaglercraft.WebSocketRateLimiter; -import java.util.Map; -import java.net.InetSocketAddress; - public class ListenerInfo { private final String hostString; private final InetSocketAddress host; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/config/ServerInfo.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/config/ServerInfo.java index 98705ed..c43cc35 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/config/ServerInfo.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/config/ServerInfo.java @@ -4,12 +4,13 @@ package net.md_5.bungee.api.config; -import net.md_5.bungee.api.ServerPing; +import java.net.InetSocketAddress; +import java.util.Collection; + import net.md_5.bungee.api.Callback; import net.md_5.bungee.api.CommandSender; +import net.md_5.bungee.api.ServerPing; import net.md_5.bungee.api.connection.ProxiedPlayer; -import java.util.Collection; -import java.net.InetSocketAddress; public interface ServerInfo { String getName(); diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/Connection.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/Connection.java index 22fba2d..9eb21e1 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/Connection.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/Connection.java @@ -4,9 +4,10 @@ package net.md_5.bungee.api.connection; -import net.md_5.bungee.protocol.packet.DefinedPacket; import java.net.InetSocketAddress; +import net.md_5.bungee.protocol.packet.DefinedPacket; + public interface Connection { InetSocketAddress getAddress(); diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/PendingConnection.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/PendingConnection.java index 24cbaba..78938ed 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/PendingConnection.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/PendingConnection.java @@ -4,9 +4,10 @@ package net.md_5.bungee.api.connection; -import net.md_5.bungee.api.config.ListenerInfo; import java.net.InetSocketAddress; +import net.md_5.bungee.api.config.ListenerInfo; + public interface PendingConnection extends Connection { String getName(); diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/ProxiedPlayer.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/ProxiedPlayer.java index e8c35a2..872607a 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/ProxiedPlayer.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/connection/ProxiedPlayer.java @@ -4,10 +4,10 @@ package net.md_5.bungee.api.connection; -import net.md_5.bungee.api.tab.TabListHandler; -import net.md_5.bungee.api.config.TexturePackInfo; -import net.md_5.bungee.api.config.ServerInfo; import net.md_5.bungee.api.CommandSender; +import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.api.config.TexturePackInfo; +import net.md_5.bungee.api.tab.TabListHandler; public interface ProxiedPlayer extends Connection, CommandSender { String getDisplayName(); diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/AsyncEvent.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/AsyncEvent.java index 0d15d10..815c9c7 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/AsyncEvent.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/AsyncEvent.java @@ -5,16 +5,17 @@ package net.md_5.bungee.api.event; import java.beans.ConstructorProperties; -import java.util.Map; import java.util.Collections; -import java.util.concurrent.ConcurrentHashMap; -import com.google.common.base.Preconditions; -import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.atomic.AtomicBoolean; -import net.md_5.bungee.api.plugin.Plugin; import java.util.Set; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.atomic.AtomicBoolean; +import java.util.concurrent.atomic.AtomicInteger; + +import com.google.common.base.Preconditions; + import net.md_5.bungee.api.Callback; import net.md_5.bungee.api.plugin.Event; +import net.md_5.bungee.api.plugin.Plugin; public class AsyncEvent extends Event { private final Callback done; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PermissionCheckEvent.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PermissionCheckEvent.java index 2fb3c95..608363a 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PermissionCheckEvent.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PermissionCheckEvent.java @@ -5,6 +5,7 @@ package net.md_5.bungee.api.event; import java.beans.ConstructorProperties; + import net.md_5.bungee.api.CommandSender; import net.md_5.bungee.api.plugin.Event; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PlayerDisconnectEvent.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PlayerDisconnectEvent.java index e0d9e5d..e68f46f 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PlayerDisconnectEvent.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PlayerDisconnectEvent.java @@ -5,6 +5,7 @@ package net.md_5.bungee.api.event; import java.beans.ConstructorProperties; + import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.plugin.Event; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PluginMessageEvent.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PluginMessageEvent.java index 58f75a5..d7fb59a 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PluginMessageEvent.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PluginMessageEvent.java @@ -5,6 +5,7 @@ package net.md_5.bungee.api.event; import java.util.Arrays; + import net.md_5.bungee.api.connection.Connection; import net.md_5.bungee.api.plugin.Cancellable; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PostLoginEvent.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PostLoginEvent.java index d5aa89a..3786df7 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PostLoginEvent.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/PostLoginEvent.java @@ -5,6 +5,7 @@ package net.md_5.bungee.api.event; import java.beans.ConstructorProperties; + import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.plugin.Event; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ProxyPingEvent.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ProxyPingEvent.java index aaeb85a..6b9686a 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ProxyPingEvent.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ProxyPingEvent.java @@ -5,6 +5,7 @@ package net.md_5.bungee.api.event; import java.beans.ConstructorProperties; + import net.md_5.bungee.api.ServerPing; import net.md_5.bungee.api.connection.PendingConnection; import net.md_5.bungee.api.plugin.Event; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ServerConnectedEvent.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ServerConnectedEvent.java index 1a337ba..1f9ae70 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ServerConnectedEvent.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ServerConnectedEvent.java @@ -5,8 +5,9 @@ package net.md_5.bungee.api.event; import java.beans.ConstructorProperties; -import net.md_5.bungee.api.connection.Server; + import net.md_5.bungee.api.connection.ProxiedPlayer; +import net.md_5.bungee.api.connection.Server; import net.md_5.bungee.api.plugin.Event; public class ServerConnectedEvent extends Event { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ServerSwitchEvent.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ServerSwitchEvent.java index 943a275..c9125f2 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ServerSwitchEvent.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/ServerSwitchEvent.java @@ -5,6 +5,7 @@ package net.md_5.bungee.api.event; import java.beans.ConstructorProperties; + import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.plugin.Event; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/TargetedEvent.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/TargetedEvent.java index deba907..8b50579 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/TargetedEvent.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/event/TargetedEvent.java @@ -5,6 +5,7 @@ package net.md_5.bungee.api.event; import java.beans.ConstructorProperties; + import net.md_5.bungee.api.connection.Connection; import net.md_5.bungee.api.plugin.Event; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/Command.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/Command.java index 60e9314..87727c6 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/Command.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/Command.java @@ -5,9 +5,11 @@ package net.md_5.bungee.api.plugin; import java.util.Arrays; -import net.md_5.bungee.api.CommandSender; + import com.google.common.base.Preconditions; +import net.md_5.bungee.api.CommandSender; + public abstract class Command { private final String name; private final String permission; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/Plugin.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/Plugin.java index b39883a..c28908b 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/Plugin.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/Plugin.java @@ -4,9 +4,10 @@ package net.md_5.bungee.api.plugin; +import java.io.File; import java.io.InputStream; import java.util.logging.Logger; -import java.io.File; + import net.md_5.bungee.api.ProxyServer; public class Plugin { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginClassloader.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginClassloader.java index 09e74f3..92a5851 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginClassloader.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginClassloader.java @@ -4,11 +4,10 @@ package net.md_5.bungee.api.plugin; -import java.util.HashSet; -import java.util.Iterator; import java.net.URL; -import java.util.Set; import java.net.URLClassLoader; +import java.util.HashSet; +import java.util.Set; public class PluginClassloader extends URLClassLoader { private static final Set allLoaders; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginDescription.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginDescription.java index e20949d..272579b 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginDescription.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginDescription.java @@ -5,8 +5,8 @@ package net.md_5.bungee.api.plugin; import java.beans.ConstructorProperties; -import java.util.HashSet; import java.io.File; +import java.util.HashSet; import java.util.Set; public class PluginDescription { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginLogger.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginLogger.java index 559e046..ae80e4b 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginLogger.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginLogger.java @@ -5,9 +5,10 @@ package net.md_5.bungee.api.plugin; import java.util.logging.LogRecord; -import net.md_5.bungee.api.ProxyServer; import java.util.logging.Logger; +import net.md_5.bungee.api.ProxyServer; + public class PluginLogger extends Logger { private String pluginName; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginManager.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginManager.java index cfe94f9..5ea586e 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginManager.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/plugin/PluginManager.java @@ -5,36 +5,35 @@ package net.md_5.bungee.api.plugin; import java.beans.ConstructorProperties; -import java.lang.reflect.Method; -import java.io.InputStream; -import java.util.jar.JarEntry; -import java.util.zip.ZipEntry; -import java.util.jar.JarFile; -import com.google.common.base.Preconditions; import java.io.File; -import java.net.URLClassLoader; -import java.net.URL; -import java.util.Iterator; -import java.util.Stack; -import java.util.Collection; -import java.util.logging.Level; - -import net.md_5.bungee.BungeeCord; -import net.md_5.bungee.api.ChatColor; -import java.util.Arrays; -import net.md_5.bungee.api.CommandSender; +import java.io.InputStream; import java.lang.annotation.Annotation; -import net.md_5.bungee.event.EventHandler; -import com.google.common.eventbus.Subscribe; +import java.lang.reflect.Method; +import java.net.URL; +import java.net.URLClassLoader; +import java.util.Arrays; +import java.util.Collection; import java.util.HashMap; import java.util.LinkedHashMap; import java.util.Map; -import net.md_5.bungee.event.EventBus; +import java.util.Stack; +import java.util.jar.JarEntry; +import java.util.jar.JarFile; +import java.util.logging.Level; +import java.util.regex.Pattern; + import org.yaml.snakeyaml.Yaml; + +import com.google.common.base.Preconditions; +import com.google.common.eventbus.Subscribe; + +import net.md_5.bungee.BungeeCord; +import net.md_5.bungee.api.ChatColor; +import net.md_5.bungee.api.CommandSender; import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.command.ConsoleCommandSender; - -import java.util.regex.Pattern; +import net.md_5.bungee.event.EventBus; +import net.md_5.bungee.event.EventHandler; public class PluginManager { private static final Pattern argsSplit; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/scheduler/ScheduledTask.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/scheduler/ScheduledTask.java index c33f6dd..3fff54d 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/scheduler/ScheduledTask.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/scheduler/ScheduledTask.java @@ -5,6 +5,7 @@ package net.md_5.bungee.api.scheduler; import java.util.concurrent.TimeUnit; + import net.md_5.bungee.api.plugin.Plugin; public interface ScheduledTask { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/scheduler/TaskScheduler.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/scheduler/TaskScheduler.java index 1cd4fe7..f1f077a 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/scheduler/TaskScheduler.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/scheduler/TaskScheduler.java @@ -5,6 +5,7 @@ package net.md_5.bungee.api.scheduler; import java.util.concurrent.TimeUnit; + import net.md_5.bungee.api.plugin.Plugin; public interface TaskScheduler { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/score/Scoreboard.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/score/Scoreboard.java index ff076d8..d98347a 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/score/Scoreboard.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/score/Scoreboard.java @@ -4,12 +4,13 @@ package net.md_5.bungee.api.score; -import java.util.HashMap; -import com.google.common.base.Preconditions; -import java.util.Collections; import java.util.Collection; +import java.util.Collections; +import java.util.HashMap; import java.util.Map; +import com.google.common.base.Preconditions; + public class Scoreboard { private String name; private Position position; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/score/Team.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/score/Team.java index 8e16e47..0646f99 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/api/score/Team.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/api/score/Team.java @@ -5,9 +5,9 @@ package net.md_5.bungee.api.score; import java.beans.ConstructorProperties; -import java.util.HashSet; -import java.util.Collections; import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; import java.util.Set; public class Team { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandAlert.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandAlert.java index d77d5ab..79a951c 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandAlert.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandAlert.java @@ -4,9 +4,9 @@ package net.md_5.bungee.command; -import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.CommandSender; +import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.plugin.Command; public class CommandAlert extends Command { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandBungee.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandBungee.java index 5cc0e2b..c1f115d 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandBungee.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandBungee.java @@ -4,9 +4,9 @@ package net.md_5.bungee.command; -import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.CommandSender; +import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.plugin.Command; public class CommandBungee extends Command { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandFind.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandFind.java index d146f5e..fb70037 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandFind.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandFind.java @@ -4,10 +4,10 @@ package net.md_5.bungee.command; -import net.md_5.bungee.api.connection.ProxiedPlayer; -import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.CommandSender; +import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.plugin.Command; public class CommandFind extends Command { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandGlobalBanIP.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandGlobalBanIP.java index 0fcbc14..3f2d323 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandGlobalBanIP.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandGlobalBanIP.java @@ -1,7 +1,6 @@ package net.md_5.bungee.command; import java.net.InetAddress; -import java.net.InetSocketAddress; import java.net.UnknownHostException; import java.util.ArrayList; import java.util.List; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandGlobalListBan.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandGlobalListBan.java index 52c36c7..05d830a 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandGlobalListBan.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandGlobalListBan.java @@ -1,7 +1,5 @@ package net.md_5.bungee.command; -import java.util.List; - import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.CommandSender; import net.md_5.bungee.api.plugin.Command; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandIP.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandIP.java index 608d5e6..35c1abd 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandIP.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandIP.java @@ -4,13 +4,12 @@ package net.md_5.bungee.command; -import net.md_5.bungee.api.connection.ProxiedPlayer; -import net.md_5.bungee.api.ProxyServer; - import java.net.InetAddress; import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.CommandSender; +import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.plugin.Command; public class CommandIP extends Command { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandList.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandList.java index 10d50e8..6a144ff 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandList.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandList.java @@ -4,18 +4,17 @@ package net.md_5.bungee.command; -import java.util.List; -import java.util.Iterator; -import java.util.Collection; -import net.md_5.bungee.Util; -import java.util.Comparator; -import java.util.Collections; -import net.md_5.bungee.api.connection.ProxiedPlayer; import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.List; + +import net.md_5.bungee.Util; import net.md_5.bungee.api.ChatColor; -import net.md_5.bungee.api.config.ServerInfo; -import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.CommandSender; +import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.plugin.Command; public class CommandList extends Command { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandPerms.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandPerms.java index 1db3eea..1aef630 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandPerms.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandPerms.java @@ -4,13 +4,12 @@ package net.md_5.bungee.command; -import java.util.Iterator; -import java.util.Set; -import net.md_5.bungee.api.ChatColor; -import java.util.Collection; -import net.md_5.bungee.api.ProxyServer; import java.util.HashSet; +import java.util.Set; + +import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.CommandSender; +import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.plugin.Command; public class CommandPerms extends Command { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandReload.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandReload.java index d5d2b37..ffba51e 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandReload.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandReload.java @@ -4,8 +4,8 @@ package net.md_5.bungee.command; -import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.BungeeCord; +import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.CommandSender; import net.md_5.bungee.api.plugin.Command; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandSend.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandSend.java index 21ee18b..52d7f5b 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandSend.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandSend.java @@ -4,12 +4,11 @@ package net.md_5.bungee.command; -import java.util.Iterator; -import net.md_5.bungee.api.config.ServerInfo; -import net.md_5.bungee.api.connection.ProxiedPlayer; -import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.CommandSender; +import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.plugin.Command; public class CommandSend extends Command { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandServer.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandServer.java index 85f69fe..35ed540 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandServer.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/CommandServer.java @@ -4,12 +4,12 @@ package net.md_5.bungee.command; -import java.util.Iterator; import java.util.Map; -import net.md_5.bungee.api.config.ServerInfo; -import net.md_5.bungee.api.ProxyServer; -import net.md_5.bungee.api.connection.ProxiedPlayer; + import net.md_5.bungee.api.CommandSender; +import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.plugin.Command; public class CommandServer extends Command { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/ConsoleCommandSender.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/ConsoleCommandSender.java index d89e7fd..51db216 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/command/ConsoleCommandSender.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/command/ConsoleCommandSender.java @@ -4,12 +4,13 @@ package net.md_5.bungee.command; +import java.util.Collection; import java.util.HashSet; import java.util.Map; import java.util.WeakHashMap; -import java.util.Collection; -import net.md_5.bungee.api.ProxyServer; + import net.md_5.bungee.api.CommandSender; +import net.md_5.bungee.api.ProxyServer; public class ConsoleCommandSender implements CommandSender { private static final ConsoleCommandSender instance; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/config/Configuration.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/config/Configuration.java index c913e4b..9b34563 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/config/Configuration.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/config/Configuration.java @@ -4,18 +4,20 @@ package net.md_5.bungee.config; +import java.util.Collection; +import java.util.Map; +import java.util.UUID; + +import com.google.common.base.Preconditions; + +import gnu.trove.map.TMap; +import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.config.AuthServiceInfo; import net.md_5.bungee.api.config.ConfigurationAdapter; -import java.util.Map; -import net.md_5.bungee.util.CaseInsensitiveMap; -import com.google.common.base.Preconditions; -import net.md_5.bungee.api.ProxyServer; -import java.util.UUID; +import net.md_5.bungee.api.config.ListenerInfo; import net.md_5.bungee.api.config.ServerInfo; import net.md_5.bungee.eaglercraft.EaglercraftBungee; -import gnu.trove.map.TMap; -import net.md_5.bungee.api.config.ListenerInfo; -import java.util.Collection; +import net.md_5.bungee.util.CaseInsensitiveMap; public class Configuration { private int timeout; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/config/YamlConfig.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/config/YamlConfig.java index 66857c1..333c7fc 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/config/YamlConfig.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/config/YamlConfig.java @@ -4,43 +4,42 @@ package net.md_5.bungee.config; -import net.md_5.bungee.tab.ServerUnique; -import net.md_5.bungee.tab.GlobalPing; -import net.md_5.bungee.tab.Global; -import net.md_5.bungee.api.tab.TabListHandler; -import net.md_5.bungee.eaglercraft.WebSocketRateLimiter; -import net.md_5.bungee.api.config.TexturePackInfo; -import net.md_5.bungee.api.ChatColor; -import java.util.HashSet; -import net.md_5.bungee.api.config.ListenerInfo; -import net.md_5.bungee.api.config.MOTDCacheConfiguration; - -import java.util.Collection; -import java.net.InetSocketAddress; -import net.md_5.bungee.Util; -import net.md_5.bungee.api.config.ServerInfo; -import java.util.logging.Level; -import net.md_5.bungee.api.ProxyServer; -import java.io.Writer; +import java.io.File; +import java.io.FileInputStream; import java.io.FileWriter; -import java.util.LinkedHashMap; +import java.io.IOException; import java.io.InputStream; -import java.util.Collections; +import java.io.Writer; +import java.net.InetSocketAddress; import java.util.ArrayList; import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; import java.util.HashMap; -import java.io.IOException; -import net.md_5.bungee.util.CaseInsensitiveMap; -import java.io.FileInputStream; -import org.yaml.snakeyaml.DumperOptions; -import java.io.File; +import java.util.HashSet; +import java.util.LinkedHashMap; import java.util.Map; import java.util.Map.Entry; +import java.util.logging.Level; +import org.yaml.snakeyaml.DumperOptions; import org.yaml.snakeyaml.Yaml; +import net.md_5.bungee.Util; +import net.md_5.bungee.api.ChatColor; +import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.config.AuthServiceInfo; import net.md_5.bungee.api.config.ConfigurationAdapter; +import net.md_5.bungee.api.config.ListenerInfo; +import net.md_5.bungee.api.config.MOTDCacheConfiguration; +import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.api.config.TexturePackInfo; +import net.md_5.bungee.api.tab.TabListHandler; +import net.md_5.bungee.eaglercraft.WebSocketRateLimiter; +import net.md_5.bungee.tab.Global; +import net.md_5.bungee.tab.GlobalPing; +import net.md_5.bungee.tab.ServerUnique; +import net.md_5.bungee.util.CaseInsensitiveMap; public class YamlConfig implements ConfigurationAdapter { private Yaml yaml; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/DownstreamBridge.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/DownstreamBridge.java index 23db430..dc1dc5e 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/DownstreamBridge.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/DownstreamBridge.java @@ -6,40 +6,38 @@ package net.md_5.bungee.connection; import java.beans.ConstructorProperties; import java.net.InetAddress; - -import net.md_5.bungee.api.event.ServerKickEvent; import java.util.Objects; -import net.md_5.bungee.protocol.packet.PacketFFKick; -import java.util.Iterator; -import com.google.common.io.ByteArrayDataOutput; + import com.google.common.io.ByteArrayDataInput; -import java.util.Collection; -import net.md_5.bungee.api.connection.Connection; -import net.md_5.bungee.api.event.PluginMessageEvent; +import com.google.common.io.ByteArrayDataOutput; import com.google.common.io.ByteStreams; -import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; -import net.md_5.bungee.api.score.Team; -import net.md_5.bungee.protocol.packet.PacketD1Team; -import net.md_5.bungee.api.score.Position; -import net.md_5.bungee.protocol.packet.PacketD0DisplayScoreboard; -import net.md_5.bungee.api.score.Score; -import net.md_5.bungee.protocol.packet.PacketCFScoreboardScore; -import net.md_5.bungee.api.score.Scoreboard; -import net.md_5.bungee.api.score.Objective; -import net.md_5.bungee.protocol.packet.PacketCEScoreboardObjective; -import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; -import net.md_5.bungee.protocol.packet.Packet0KeepAlive; + import net.md_5.bungee.BungeeCord; import net.md_5.bungee.EntityMap; -import net.md_5.bungee.api.connection.ProxiedPlayer; -import net.md_5.bungee.netty.ChannelWrapper; -import net.md_5.bungee.api.config.ServerInfo; -import net.md_5.bungee.Util; -import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.ServerConnection; import net.md_5.bungee.UserConnection; +import net.md_5.bungee.Util; +import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.api.connection.ProxiedPlayer; +import net.md_5.bungee.api.event.PluginMessageEvent; +import net.md_5.bungee.api.event.ServerKickEvent; +import net.md_5.bungee.api.score.Objective; +import net.md_5.bungee.api.score.Position; +import net.md_5.bungee.api.score.Score; +import net.md_5.bungee.api.score.Scoreboard; +import net.md_5.bungee.api.score.Team; +import net.md_5.bungee.netty.ChannelWrapper; import net.md_5.bungee.netty.PacketHandler; +import net.md_5.bungee.protocol.packet.Packet0KeepAlive; +import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; +import net.md_5.bungee.protocol.packet.PacketCEScoreboardObjective; +import net.md_5.bungee.protocol.packet.PacketCFScoreboardScore; +import net.md_5.bungee.protocol.packet.PacketD0DisplayScoreboard; +import net.md_5.bungee.protocol.packet.PacketD1Team; +import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; +import net.md_5.bungee.protocol.packet.PacketFFKick; public class DownstreamBridge extends PacketHandler { private final ProxyServer bungee; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/InitialHandler.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/InitialHandler.java index 9bacd83..9786915 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/InitialHandler.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/InitialHandler.java @@ -5,59 +5,57 @@ package net.md_5.bungee.connection; import java.beans.ConstructorProperties; -import java.util.ArrayList; import java.net.InetAddress; import java.net.InetSocketAddress; -import net.md_5.bungee.protocol.packet.PacketFFKick; -import net.md_5.bungee.api.config.ServerInfo; -import net.md_5.bungee.netty.HandlerBoss; -import net.md_5.bungee.api.event.PostLoginEvent; -import net.md_5.bungee.UserConnection; -import net.md_5.bungee.protocol.packet.PacketCDClientStatus; -import net.md_5.bungee.api.connection.ProxiedPlayer; import java.security.GeneralSecurityException; -import net.md_5.bungee.netty.CipherEncoder; -import net.md_5.bungee.api.event.LoginEvent; -import net.md_5.bungee.api.Callback; -import javax.crypto.Cipher; -import java.math.BigInteger; -import java.security.MessageDigest; -import java.net.URLEncoder; -import io.netty.channel.ChannelHandler; -import net.md_5.bungee.netty.CipherDecoder; -import net.md_5.bungee.netty.PipelineUtils; -import java.security.Key; -import net.md_5.bungee.protocol.packet.PacketFCEncryptionResponse; -import net.md_5.bungee.EncryptionUtil; -import net.md_5.bungee.protocol.packet.DefinedPacket; -import net.md_5.bungee.PacketConstants; -import net.md_5.bungee.BungeeCord; +import java.util.ArrayList; +import java.util.List; import java.util.logging.Level; -import net.md_5.bungee.protocol.Protocol; -import net.md_5.bungee.protocol.Forge; -import net.md_5.bungee.netty.PacketDecoder; + +import javax.crypto.Cipher; +import javax.crypto.SecretKey; + import com.google.common.base.Preconditions; + +import io.netty.channel.ChannelHandler; +import net.md_5.bungee.BungeeCord; +import net.md_5.bungee.EncryptionUtil; +import net.md_5.bungee.PacketConstants; +import net.md_5.bungee.UserConnection; +import net.md_5.bungee.Util; +import net.md_5.bungee.api.Callback; +import net.md_5.bungee.api.ChatColor; +import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.ServerPing; +import net.md_5.bungee.api.config.ListenerInfo; +import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.api.connection.Connection; +import net.md_5.bungee.api.connection.PendingConnection; +import net.md_5.bungee.api.connection.ProxiedPlayer; +import net.md_5.bungee.api.event.LoginEvent; +import net.md_5.bungee.api.event.PostLoginEvent; import net.md_5.bungee.api.event.ProxyPingEvent; import net.md_5.bungee.eaglercraft.BanList; -import net.md_5.bungee.eaglercraft.WebSocketProxy; import net.md_5.bungee.eaglercraft.BanList.BanCheck; import net.md_5.bungee.eaglercraft.BanList.BanState; -import net.md_5.bungee.api.ServerPing; -import net.md_5.bungee.protocol.packet.PacketFEPing; -import net.md_5.bungee.Util; -import net.md_5.bungee.api.ChatColor; -import net.md_5.bungee.api.connection.Connection; -import javax.crypto.SecretKey; -import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; -import java.util.List; -import net.md_5.bungee.protocol.packet.PacketFDEncryptionRequest; -import net.md_5.bungee.protocol.packet.Packet2Handshake; -import net.md_5.bungee.protocol.packet.Packet1Login; -import net.md_5.bungee.api.config.ListenerInfo; +import net.md_5.bungee.eaglercraft.WebSocketProxy; import net.md_5.bungee.netty.ChannelWrapper; -import net.md_5.bungee.api.ProxyServer; -import net.md_5.bungee.api.connection.PendingConnection; +import net.md_5.bungee.netty.CipherDecoder; +import net.md_5.bungee.netty.CipherEncoder; +import net.md_5.bungee.netty.HandlerBoss; +import net.md_5.bungee.netty.PacketDecoder; import net.md_5.bungee.netty.PacketHandler; +import net.md_5.bungee.netty.PipelineUtils; +import net.md_5.bungee.protocol.Forge; +import net.md_5.bungee.protocol.packet.DefinedPacket; +import net.md_5.bungee.protocol.packet.Packet1Login; +import net.md_5.bungee.protocol.packet.Packet2Handshake; +import net.md_5.bungee.protocol.packet.PacketCDClientStatus; +import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; +import net.md_5.bungee.protocol.packet.PacketFCEncryptionResponse; +import net.md_5.bungee.protocol.packet.PacketFDEncryptionRequest; +import net.md_5.bungee.protocol.packet.PacketFEPing; +import net.md_5.bungee.protocol.packet.PacketFFKick; public class InitialHandler extends PacketHandler implements PendingConnection { private final ProxyServer bungee; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/PingHandler.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/PingHandler.java index 6e55bf1..39cb617 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/PingHandler.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/PingHandler.java @@ -5,12 +5,13 @@ package net.md_5.bungee.connection; import java.beans.ConstructorProperties; -import net.md_5.bungee.protocol.packet.PacketFFKick; -import net.md_5.bungee.netty.ChannelWrapper; -import net.md_5.bungee.api.ServerPing; + import net.md_5.bungee.api.Callback; +import net.md_5.bungee.api.ServerPing; import net.md_5.bungee.api.config.ServerInfo; +import net.md_5.bungee.netty.ChannelWrapper; import net.md_5.bungee.netty.PacketHandler; +import net.md_5.bungee.protocol.packet.PacketFFKick; public class PingHandler extends PacketHandler { private final ServerInfo target; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/UpstreamBridge.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/UpstreamBridge.java index 2b448ba..6e550f0 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/UpstreamBridge.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/connection/UpstreamBridge.java @@ -4,25 +4,21 @@ package net.md_5.bungee.connection; -import net.md_5.bungee.api.event.PluginMessageEvent; -import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; -import net.md_5.bungee.protocol.packet.PacketCCSettings; -import net.md_5.bungee.api.CommandSender; -import net.md_5.bungee.api.connection.Connection; -import net.md_5.bungee.api.event.ChatEvent; -import net.md_5.bungee.protocol.packet.Packet3Chat; -import net.md_5.bungee.protocol.packet.Packet0KeepAlive; -import net.md_5.bungee.EntityMap; -import net.md_5.bungee.api.connection.ProxiedPlayer; -import net.md_5.bungee.api.event.PlayerDisconnectEvent; -import net.md_5.bungee.netty.ChannelWrapper; -import net.md_5.bungee.Util; -import net.md_5.bungee.api.config.TexturePackInfo; -import net.md_5.bungee.protocol.packet.DefinedPacket; import net.md_5.bungee.BungeeCord; +import net.md_5.bungee.EntityMap; import net.md_5.bungee.UserConnection; +import net.md_5.bungee.Util; import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.config.TexturePackInfo; +import net.md_5.bungee.api.event.ChatEvent; +import net.md_5.bungee.api.event.PlayerDisconnectEvent; +import net.md_5.bungee.api.event.PluginMessageEvent; +import net.md_5.bungee.netty.ChannelWrapper; import net.md_5.bungee.netty.PacketHandler; +import net.md_5.bungee.protocol.packet.Packet0KeepAlive; +import net.md_5.bungee.protocol.packet.Packet3Chat; +import net.md_5.bungee.protocol.packet.PacketCCSettings; +import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; public class UpstreamBridge extends PacketHandler { private final ProxyServer bungee; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/eaglercraft/PluginEaglerAuth.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/eaglercraft/PluginEaglerAuth.java index 81316ef..14bd16a 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/eaglercraft/PluginEaglerAuth.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/eaglercraft/PluginEaglerAuth.java @@ -3,7 +3,6 @@ package net.md_5.bungee.eaglercraft; import java.util.Collections; import java.util.HashSet; -import net.md_5.bungee.PacketConstants; import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.event.PostLoginEvent; import net.md_5.bungee.api.event.ServerConnectEvent; @@ -11,8 +10,6 @@ import net.md_5.bungee.api.plugin.Listener; import net.md_5.bungee.api.plugin.Plugin; import net.md_5.bungee.api.plugin.PluginDescription; import net.md_5.bungee.event.EventHandler; -import net.md_5.bungee.protocol.packet.Packet1Login; -import net.md_5.bungee.protocol.packet.Packet9Respawn; public class PluginEaglerAuth extends Plugin implements Listener { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/eaglercraft/PluginEaglerVoice.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/eaglercraft/PluginEaglerVoice.java index ed82955..48c6c25 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/eaglercraft/PluginEaglerVoice.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/eaglercraft/PluginEaglerVoice.java @@ -1,5 +1,18 @@ package net.md_5.bungee.eaglercraft; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.DataInputStream; +import java.io.DataOutputStream; +import java.io.EOFException; +import java.io.IOException; +import java.util.Collection; +import java.util.Collections; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Map; +import java.util.Set; + import net.md_5.bungee.BungeeCord; import net.md_5.bungee.UserConnection; import net.md_5.bungee.api.event.PlayerDisconnectEvent; @@ -10,14 +23,6 @@ import net.md_5.bungee.api.plugin.Plugin; import net.md_5.bungee.api.plugin.PluginDescription; import net.md_5.bungee.event.EventHandler; -import java.io.*; -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; -import java.util.Set; -import java.util.Collection; -import java.util.Collections; - public class PluginEaglerVoice extends Plugin implements Listener { private final boolean voiceEnabled; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/event/EventBus.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/event/EventBus.java index bec77ba..27b32ad 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/event/EventBus.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/event/EventBus.java @@ -4,19 +4,18 @@ package net.md_5.bungee.event; -import java.util.HashSet; -import java.util.Set; -import java.util.Iterator; -import java.lang.reflect.InvocationTargetException; -import java.text.MessageFormat; -import java.util.logging.Level; -import java.util.concurrent.locks.ReentrantReadWriteLock; -import java.util.HashMap; import java.lang.annotation.Annotation; -import java.util.logging.Logger; -import java.util.concurrent.locks.ReadWriteLock; +import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; +import java.text.MessageFormat; +import java.util.HashMap; +import java.util.HashSet; import java.util.Map; +import java.util.Set; +import java.util.concurrent.locks.ReadWriteLock; +import java.util.concurrent.locks.ReentrantReadWriteLock; +import java.util.logging.Level; +import java.util.logging.Logger; public class EventBus { private final Map, Map> eventToHandler; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/event/EventHandler.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/event/EventHandler.java index 1920c2f..7abf0eb 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/event/EventHandler.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/event/EventHandler.java @@ -5,10 +5,9 @@ package net.md_5.bungee.event; import java.lang.annotation.ElementType; -import java.lang.annotation.Target; -import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Retention; -import java.lang.annotation.Annotation; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; @Retention(RetentionPolicy.RUNTIME) @Target({ ElementType.METHOD }) diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/log/BungeeLogger.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/log/BungeeLogger.java index a8bc900..48341b0 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/log/BungeeLogger.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/log/BungeeLogger.java @@ -4,14 +4,14 @@ package net.md_5.bungee.log; -import java.util.logging.LogRecord; import java.io.IOException; -import java.util.logging.Handler; import java.util.logging.FileHandler; import java.util.logging.Formatter; -import net.md_5.bungee.BungeeCord; +import java.util.logging.LogRecord; import java.util.logging.Logger; +import net.md_5.bungee.BungeeCord; + public class BungeeLogger extends Logger { private final BungeeCord bungee; private final ColouredWriter writer; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/log/ColouredWriter.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/log/ColouredWriter.java index bf29edd..0aa57ab 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/log/ColouredWriter.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/log/ColouredWriter.java @@ -5,11 +5,13 @@ package net.md_5.bungee.log; import java.io.IOException; -import org.fusesource.jansi.Ansi; import java.util.EnumMap; +import java.util.Map; + +import org.fusesource.jansi.Ansi; + import jline.console.ConsoleReader; import net.md_5.bungee.api.ChatColor; -import java.util.Map; public class ColouredWriter { private final Map replacements; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/log/ConciseFormatter.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/log/ConciseFormatter.java index 7745629..fbee535 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/log/ConciseFormatter.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/log/ConciseFormatter.java @@ -4,13 +4,12 @@ package net.md_5.bungee.log; -import java.io.Writer; import java.io.PrintWriter; import java.io.StringWriter; -import java.util.logging.LogRecord; -import java.text.SimpleDateFormat; import java.text.DateFormat; +import java.text.SimpleDateFormat; import java.util.logging.Formatter; +import java.util.logging.LogRecord; public class ConciseFormatter extends Formatter { private final DateFormat date; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/log/LogDispatcher.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/log/LogDispatcher.java index 083841c..c33938f 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/log/LogDispatcher.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/log/LogDispatcher.java @@ -4,10 +4,9 @@ package net.md_5.bungee.log; -import java.util.Iterator; +import java.util.concurrent.BlockingQueue; import java.util.concurrent.LinkedBlockingQueue; import java.util.logging.LogRecord; -import java.util.concurrent.BlockingQueue; public class LogDispatcher extends Thread { private final BungeeLogger logger; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/log/LoggingOutputStream.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/log/LoggingOutputStream.java index c76b0a6..1667439 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/log/LoggingOutputStream.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/log/LoggingOutputStream.java @@ -5,10 +5,10 @@ package net.md_5.bungee.log; import java.beans.ConstructorProperties; +import java.io.ByteArrayOutputStream; import java.io.IOException; import java.util.logging.Level; import java.util.logging.Logger; -import java.io.ByteArrayOutputStream; public class LoggingOutputStream extends ByteArrayOutputStream { private static final String separator; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/ChannelWrapper.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/ChannelWrapper.java index 3430f00..429eb3b 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/ChannelWrapper.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/ChannelWrapper.java @@ -4,8 +4,8 @@ package net.md_5.bungee.netty; -import io.netty.channel.ChannelHandlerContext; import io.netty.channel.Channel; +import io.netty.channel.ChannelHandlerContext; public class ChannelWrapper { private final Channel ch; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherBase.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherBase.java index 92f2d81..de8fc23 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherBase.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherBase.java @@ -5,10 +5,12 @@ package net.md_5.bungee.netty; import java.beans.ConstructorProperties; -import javax.crypto.ShortBufferException; -import io.netty.channel.ChannelHandlerContext; -import io.netty.buffer.ByteBuf; + import javax.crypto.Cipher; +import javax.crypto.ShortBufferException; + +import io.netty.buffer.ByteBuf; +import io.netty.channel.ChannelHandlerContext; public class CipherBase { private final Cipher cipher; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherDecoder.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherDecoder.java index c2f03df..4d07f48 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherDecoder.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherDecoder.java @@ -4,10 +4,11 @@ package net.md_5.bungee.netty; -import io.netty.channel.MessageList; -import io.netty.channel.ChannelHandlerContext; import javax.crypto.Cipher; + import io.netty.buffer.ByteBuf; +import io.netty.channel.ChannelHandlerContext; +import io.netty.channel.MessageList; import io.netty.handler.codec.MessageToMessageDecoder; public class CipherDecoder extends MessageToMessageDecoder { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherEncoder.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherEncoder.java index 68184c1..0afc086 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherEncoder.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/CipherEncoder.java @@ -4,9 +4,10 @@ package net.md_5.bungee.netty; -import io.netty.channel.ChannelHandlerContext; import javax.crypto.Cipher; + import io.netty.buffer.ByteBuf; +import io.netty.channel.ChannelHandlerContext; import io.netty.handler.codec.MessageToByteEncoder; public class CipherEncoder extends MessageToByteEncoder { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/DefinedPacketEncoder.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/DefinedPacketEncoder.java index da47687..57b6548 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/DefinedPacketEncoder.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/DefinedPacketEncoder.java @@ -5,10 +5,10 @@ package net.md_5.bungee.netty; import io.netty.buffer.ByteBuf; -import io.netty.channel.ChannelHandlerContext; import io.netty.channel.ChannelHandler; -import net.md_5.bungee.protocol.packet.DefinedPacket; +import io.netty.channel.ChannelHandlerContext; import io.netty.handler.codec.MessageToByteEncoder; +import net.md_5.bungee.protocol.packet.DefinedPacket; @ChannelHandler.Sharable public class DefinedPacketEncoder extends MessageToByteEncoder { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/HandlerBoss.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/HandlerBoss.java index 4d432e9..065f4bc 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/HandlerBoss.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/HandlerBoss.java @@ -5,18 +5,18 @@ package net.md_5.bungee.netty; import java.io.IOException; -import io.netty.handler.timeout.ReadTimeoutException; -import java.util.Iterator; -import net.md_5.bungee.connection.CancelSendSignal; -import net.md_5.bungee.protocol.packet.AbstractPacketHandler; -import io.netty.channel.MessageList; import java.util.logging.Level; -import net.md_5.bungee.api.ProxyServer; -import net.md_5.bungee.connection.PingHandler; -import net.md_5.bungee.connection.InitialHandler; -import io.netty.channel.ChannelHandlerContext; + import com.google.common.base.Preconditions; + +import io.netty.channel.ChannelHandlerContext; import io.netty.channel.ChannelInboundHandlerAdapter; +import io.netty.channel.MessageList; +import io.netty.handler.timeout.ReadTimeoutException; +import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.connection.CancelSendSignal; +import net.md_5.bungee.connection.InitialHandler; +import net.md_5.bungee.connection.PingHandler; public class HandlerBoss extends ChannelInboundHandlerAdapter { private ChannelWrapper channel; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/PacketDecoder.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/PacketDecoder.java index d7f60bc..12dcd41 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/PacketDecoder.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/PacketDecoder.java @@ -5,12 +5,13 @@ package net.md_5.bungee.netty; import java.beans.ConstructorProperties; -import net.md_5.bungee.protocol.packet.DefinedPacket; -import io.netty.channel.MessageList; + import io.netty.buffer.ByteBuf; import io.netty.channel.ChannelHandlerContext; -import net.md_5.bungee.protocol.Protocol; +import io.netty.channel.MessageList; import io.netty.handler.codec.ReplayingDecoder; +import net.md_5.bungee.protocol.Protocol; +import net.md_5.bungee.protocol.packet.DefinedPacket; public class PacketDecoder extends ReplayingDecoder { private Protocol protocol; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/PipelineUtils.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/PipelineUtils.java index 23e6333..1caf83d 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/PipelineUtils.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/netty/PipelineUtils.java @@ -4,24 +4,24 @@ package net.md_5.bungee.netty; -import net.md_5.bungee.protocol.Protocol; -import net.md_5.bungee.protocol.Vanilla; -import io.netty.channel.ChannelHandler; -import io.netty.handler.timeout.ReadTimeoutHandler; import java.util.concurrent.TimeUnit; -import net.md_5.bungee.BungeeCord; -import io.netty.channel.ChannelException; -import io.netty.channel.ChannelOption; -import net.md_5.bungee.ServerConnector; -import net.md_5.bungee.connection.InitialHandler; -import net.md_5.bungee.api.ProxyServer; -import io.netty.handler.codec.bytes.ByteArrayEncoder; + import io.netty.channel.Channel; +import io.netty.channel.ChannelException; +import io.netty.channel.ChannelHandler; import io.netty.channel.ChannelInitializer; -import net.md_5.bungee.BungeeServerInfo; -import net.md_5.bungee.UserConnection; -import net.md_5.bungee.api.config.ListenerInfo; +import io.netty.channel.ChannelOption; +import io.netty.handler.codec.bytes.ByteArrayEncoder; +import io.netty.handler.timeout.ReadTimeoutHandler; import io.netty.util.AttributeKey; +import net.md_5.bungee.BungeeCord; +import net.md_5.bungee.BungeeServerInfo; +import net.md_5.bungee.ServerConnector; +import net.md_5.bungee.UserConnection; +import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.config.ListenerInfo; +import net.md_5.bungee.connection.InitialHandler; +import net.md_5.bungee.protocol.Vanilla; public class PipelineUtils { public static final AttributeKey LISTENER; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Forge.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Forge.java index a568d77..4c94440 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Forge.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Forge.java @@ -4,10 +4,10 @@ package net.md_5.bungee.protocol; -import net.md_5.bungee.protocol.packet.DefinedPacket; import io.netty.buffer.ByteBuf; -import net.md_5.bungee.protocol.skip.PacketReader; +import net.md_5.bungee.protocol.packet.DefinedPacket; import net.md_5.bungee.protocol.packet.forge.Forge1Login; +import net.md_5.bungee.protocol.skip.PacketReader; public class Forge extends Vanilla { private static final Forge instance; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Protocol.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Protocol.java index f4eb7e5..f548b7f 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Protocol.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Protocol.java @@ -5,8 +5,9 @@ package net.md_5.bungee.protocol; import java.lang.reflect.Constructor; -import net.md_5.bungee.protocol.packet.DefinedPacket; + import io.netty.buffer.ByteBuf; +import net.md_5.bungee.protocol.packet.DefinedPacket; import net.md_5.bungee.protocol.skip.PacketReader; public interface Protocol { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Vanilla.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Vanilla.java index c519126..2653275 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Vanilla.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/Vanilla.java @@ -4,28 +4,29 @@ package net.md_5.bungee.protocol; -import java.lang.reflect.InvocationTargetException; -import io.netty.buffer.ByteBuf; -import net.md_5.bungee.protocol.packet.PacketFFKick; -import net.md_5.bungee.protocol.packet.PacketFEPing; -import net.md_5.bungee.protocol.packet.PacketFDEncryptionRequest; -import net.md_5.bungee.protocol.packet.PacketFCEncryptionResponse; -import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; -import net.md_5.bungee.protocol.packet.PacketD1Team; -import net.md_5.bungee.protocol.packet.PacketD0DisplayScoreboard; -import net.md_5.bungee.protocol.packet.PacketCFScoreboardScore; -import net.md_5.bungee.protocol.packet.PacketCEScoreboardObjective; -import net.md_5.bungee.protocol.packet.PacketCDClientStatus; -import net.md_5.bungee.protocol.packet.PacketCCSettings; -import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; -import net.md_5.bungee.protocol.packet.Packet9Respawn; -import net.md_5.bungee.protocol.packet.Packet3Chat; -import net.md_5.bungee.protocol.packet.Packet2Handshake; -import net.md_5.bungee.protocol.packet.Packet1Login; -import net.md_5.bungee.protocol.packet.Packet0KeepAlive; -import net.md_5.bungee.protocol.skip.PacketReader; import java.lang.reflect.Constructor; +import java.lang.reflect.InvocationTargetException; + +import io.netty.buffer.ByteBuf; import net.md_5.bungee.protocol.packet.DefinedPacket; +import net.md_5.bungee.protocol.packet.Packet0KeepAlive; +import net.md_5.bungee.protocol.packet.Packet1Login; +import net.md_5.bungee.protocol.packet.Packet2Handshake; +import net.md_5.bungee.protocol.packet.Packet3Chat; +import net.md_5.bungee.protocol.packet.Packet9Respawn; +import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; +import net.md_5.bungee.protocol.packet.PacketCCSettings; +import net.md_5.bungee.protocol.packet.PacketCDClientStatus; +import net.md_5.bungee.protocol.packet.PacketCEScoreboardObjective; +import net.md_5.bungee.protocol.packet.PacketCFScoreboardScore; +import net.md_5.bungee.protocol.packet.PacketD0DisplayScoreboard; +import net.md_5.bungee.protocol.packet.PacketD1Team; +import net.md_5.bungee.protocol.packet.PacketFAPluginMessage; +import net.md_5.bungee.protocol.packet.PacketFCEncryptionResponse; +import net.md_5.bungee.protocol.packet.PacketFDEncryptionRequest; +import net.md_5.bungee.protocol.packet.PacketFEPing; +import net.md_5.bungee.protocol.packet.PacketFFKick; +import net.md_5.bungee.protocol.skip.PacketReader; public class Vanilla implements Protocol { public static final byte PROTOCOL_VERSION = 61; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/DefinedPacket.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/DefinedPacket.java index 56529e8..079168c 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/DefinedPacket.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/DefinedPacket.java @@ -5,6 +5,7 @@ package net.md_5.bungee.protocol.packet; import java.beans.ConstructorProperties; + import io.netty.buffer.ByteBuf; public abstract class DefinedPacket { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketD1Team.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketD1Team.java index 4e5831a..ad5e146 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketD1Team.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketD1Team.java @@ -5,6 +5,7 @@ package net.md_5.bungee.protocol.packet; import java.util.Arrays; + import io.netty.buffer.ByteBuf; public class PacketD1Team extends DefinedPacket { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFAPluginMessage.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFAPluginMessage.java index 21cf27e..6837808 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFAPluginMessage.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFAPluginMessage.java @@ -5,6 +5,7 @@ package net.md_5.bungee.protocol.packet; import java.util.Arrays; + import io.netty.buffer.ByteBuf; public class PacketFAPluginMessage extends DefinedPacket { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFCEncryptionResponse.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFCEncryptionResponse.java index 3070ddd..5071f12 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFCEncryptionResponse.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFCEncryptionResponse.java @@ -5,6 +5,7 @@ package net.md_5.bungee.protocol.packet; import java.util.Arrays; + import io.netty.buffer.ByteBuf; public class PacketFCEncryptionResponse extends DefinedPacket { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFDEncryptionRequest.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFDEncryptionRequest.java index c5ee4ed..741bfb7 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFDEncryptionRequest.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/PacketFDEncryptionRequest.java @@ -5,6 +5,7 @@ package net.md_5.bungee.protocol.packet; import java.util.Arrays; + import io.netty.buffer.ByteBuf; public class PacketFDEncryptionRequest extends DefinedPacket { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/forge/Forge1Login.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/forge/Forge1Login.java index c722a1c..4306fb4 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/forge/Forge1Login.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/packet/forge/Forge1Login.java @@ -4,8 +4,8 @@ package net.md_5.bungee.protocol.packet.forge; -import net.md_5.bungee.protocol.packet.AbstractPacketHandler; import io.netty.buffer.ByteBuf; +import net.md_5.bungee.protocol.packet.AbstractPacketHandler; import net.md_5.bungee.protocol.packet.Packet1Login; public class Forge1Login extends Packet1Login { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/skip/PacketReader.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/skip/PacketReader.java index fb602f4..f68c5f7 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/skip/PacketReader.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/protocol/skip/PacketReader.java @@ -4,10 +4,11 @@ package net.md_5.bungee.protocol.skip; +import java.util.ArrayList; +import java.util.List; + import io.netty.buffer.ByteBuf; import net.md_5.bungee.protocol.OpCode; -import java.util.List; -import java.util.ArrayList; import net.md_5.bungee.protocol.Protocol; public class PacketReader { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/reconnect/AbstractReconnectManager.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/reconnect/AbstractReconnectManager.java index 9884596..897c2e0 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/reconnect/AbstractReconnectManager.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/reconnect/AbstractReconnectManager.java @@ -4,12 +4,13 @@ package net.md_5.bungee.reconnect; -import net.md_5.bungee.api.config.ListenerInfo; import com.google.common.base.Preconditions; + import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.ReconnectHandler; +import net.md_5.bungee.api.config.ListenerInfo; import net.md_5.bungee.api.config.ServerInfo; import net.md_5.bungee.api.connection.ProxiedPlayer; -import net.md_5.bungee.api.ReconnectHandler; public abstract class AbstractReconnectManager implements ReconnectHandler { @Override diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/reconnect/SQLReconnectHandler.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/reconnect/SQLReconnectHandler.java index 6545a53..4e4dfbf 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/reconnect/SQLReconnectHandler.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/reconnect/SQLReconnectHandler.java @@ -4,14 +4,15 @@ package net.md_5.bungee.reconnect; +import java.sql.Connection; +import java.sql.DriverManager; +import java.sql.PreparedStatement; import java.sql.ResultSet; +import java.sql.SQLException; import java.util.logging.Level; + import net.md_5.bungee.api.ProxyServer; import net.md_5.bungee.api.connection.ProxiedPlayer; -import java.sql.SQLException; -import java.sql.PreparedStatement; -import java.sql.DriverManager; -import java.sql.Connection; public class SQLReconnectHandler extends AbstractReconnectManager { private final Connection connection; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeScheduler.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeScheduler.java index afbf4c3..f0b2e3e 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeScheduler.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeScheduler.java @@ -4,20 +4,22 @@ package net.md_5.bungee.scheduler; -import com.google.common.base.Preconditions; -import net.md_5.bungee.BungeeCord; -import java.util.concurrent.TimeUnit; -import java.util.Set; import java.util.HashSet; -import net.md_5.bungee.api.scheduler.ScheduledTask; -import com.google.common.collect.Multimaps; -import com.google.common.collect.HashMultimap; -import gnu.trove.TCollections; -import gnu.trove.map.hash.TIntObjectHashMap; -import net.md_5.bungee.api.plugin.Plugin; -import com.google.common.collect.Multimap; -import gnu.trove.map.TIntObjectMap; +import java.util.Set; +import java.util.concurrent.TimeUnit; import java.util.concurrent.atomic.AtomicInteger; + +import com.google.common.base.Preconditions; +import com.google.common.collect.HashMultimap; +import com.google.common.collect.Multimap; +import com.google.common.collect.Multimaps; + +import gnu.trove.TCollections; +import gnu.trove.map.TIntObjectMap; +import gnu.trove.map.hash.TIntObjectHashMap; +import net.md_5.bungee.BungeeCord; +import net.md_5.bungee.api.plugin.Plugin; +import net.md_5.bungee.api.scheduler.ScheduledTask; import net.md_5.bungee.api.scheduler.TaskScheduler; public class BungeeScheduler implements TaskScheduler { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeTask.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeTask.java index 0ee44e5..23aa0c4 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeTask.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeTask.java @@ -5,8 +5,9 @@ package net.md_5.bungee.scheduler; import java.beans.ConstructorProperties; -import java.util.concurrent.TimeUnit; import java.util.concurrent.ScheduledFuture; +import java.util.concurrent.TimeUnit; + import net.md_5.bungee.api.plugin.Plugin; import net.md_5.bungee.api.scheduler.ScheduledTask; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeThreadPool.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeThreadPool.java index f729b26..e17f277 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeThreadPool.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/scheduler/BungeeThreadPool.java @@ -4,11 +4,12 @@ package net.md_5.bungee.scheduler; -import java.util.logging.Level; -import net.md_5.bungee.api.ProxyServer; -import java.util.concurrent.TimeUnit; -import java.util.concurrent.ThreadFactory; import java.util.concurrent.ScheduledThreadPoolExecutor; +import java.util.concurrent.ThreadFactory; +import java.util.concurrent.TimeUnit; +import java.util.logging.Level; + +import net.md_5.bungee.api.ProxyServer; public class BungeeThreadPool extends ScheduledThreadPoolExecutor { public BungeeThreadPool(final ThreadFactory threadFactory) { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/Custom.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/Custom.java index 386d0bc..d05f4a2 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/Custom.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/Custom.java @@ -4,14 +4,16 @@ package net.md_5.bungee.tab; -import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; -import net.md_5.bungee.api.ChatColor; -import com.google.common.base.Preconditions; -import java.util.HashSet; -import net.md_5.bungee.api.connection.ProxiedPlayer; import java.util.Collection; +import java.util.HashSet; + +import com.google.common.base.Preconditions; + +import net.md_5.bungee.api.ChatColor; +import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.tab.CustomTabList; import net.md_5.bungee.api.tab.TabListAdapter; +import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; public class Custom extends TabListAdapter implements CustomTabList { private static final int ROWS = 20; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/Global.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/Global.java index 8ec303f..23963f9 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/Global.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/Global.java @@ -4,13 +4,11 @@ package net.md_5.bungee.tab; -import java.util.Iterator; import net.md_5.bungee.BungeeCord; -import net.md_5.bungee.protocol.packet.DefinedPacket; -import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; -import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.ProxyServer; +import net.md_5.bungee.api.connection.ProxiedPlayer; import net.md_5.bungee.api.tab.TabListAdapter; +import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; public class Global extends TabListAdapter { private boolean sentPing; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/GlobalPing.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/GlobalPing.java index 90a816d..9b3b981 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/GlobalPing.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/GlobalPing.java @@ -4,9 +4,8 @@ package net.md_5.bungee.tab; -import net.md_5.bungee.protocol.packet.DefinedPacket; -import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; import net.md_5.bungee.BungeeCord; +import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; public class GlobalPing extends Global { private static final int PING_THRESHOLD = 20; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/ServerUnique.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/ServerUnique.java index 855f3a7..ccaf030 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/ServerUnique.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/tab/ServerUnique.java @@ -4,12 +4,11 @@ package net.md_5.bungee.tab; -import java.util.Iterator; -import net.md_5.bungee.protocol.packet.DefinedPacket; -import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; -import java.util.HashSet; import java.util.Collection; +import java.util.HashSet; + import net.md_5.bungee.api.tab.TabListAdapter; +import net.md_5.bungee.protocol.packet.PacketC9PlayerListItem; public class ServerUnique extends TabListAdapter { private final Collection usernames; diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/util/CaseInsensitiveMap.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/util/CaseInsensitiveMap.java index 67ba884..f683511 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/util/CaseInsensitiveMap.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/util/CaseInsensitiveMap.java @@ -5,8 +5,9 @@ package net.md_5.bungee.util; import java.util.Map; -import gnu.trove.strategy.HashingStrategy; + import gnu.trove.map.hash.TCustomHashMap; +import gnu.trove.strategy.HashingStrategy; public class CaseInsensitiveMap extends TCustomHashMap { public CaseInsensitiveMap() { diff --git a/eaglercraftbungee/src/main/java/net/md_5/bungee/util/CaseInsensitiveSet.java b/eaglercraftbungee/src/main/java/net/md_5/bungee/util/CaseInsensitiveSet.java index 2543e8c..6bff97c 100644 --- a/eaglercraftbungee/src/main/java/net/md_5/bungee/util/CaseInsensitiveSet.java +++ b/eaglercraftbungee/src/main/java/net/md_5/bungee/util/CaseInsensitiveSet.java @@ -5,8 +5,9 @@ package net.md_5.bungee.util; import java.util.Collection; -import gnu.trove.strategy.HashingStrategy; + import gnu.trove.set.hash.TCustomHashSet; +import gnu.trove.strategy.HashingStrategy; public class CaseInsensitiveSet extends TCustomHashSet { public CaseInsensitiveSet() { diff --git a/src/main/java/net/lax1dude/eaglercraft/BaseNCodec.java b/src/main/java/net/lax1dude/eaglercraft/BaseNCodec.java index 4478555..cd78ed3 100644 --- a/src/main/java/net/lax1dude/eaglercraft/BaseNCodec.java +++ b/src/main/java/net/lax1dude/eaglercraft/BaseNCodec.java @@ -3,8 +3,6 @@ package net.lax1dude.eaglercraft; import java.nio.charset.Charset; import java.util.Arrays; -import net.lax1dude.eaglercraft.BaseNCodec.CodecPolicy; - public abstract class BaseNCodec { static enum CodecPolicy { diff --git a/src/main/java/net/lax1dude/eaglercraft/EarlyLoadScreen.java b/src/main/java/net/lax1dude/eaglercraft/EarlyLoadScreen.java index 4851e13..183afa3 100644 --- a/src/main/java/net/lax1dude/eaglercraft/EarlyLoadScreen.java +++ b/src/main/java/net/lax1dude/eaglercraft/EarlyLoadScreen.java @@ -1,10 +1,68 @@ package net.lax1dude.eaglercraft; -import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.*; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_ARRAY_BUFFER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_CLAMP; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_COLOR_BUFFER_BIT; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_DEPTH_BUFFER_BIT; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_FLOAT; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_FRAGMENT_SHADER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_NEAREST; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_RGBA; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_STATIC_DRAW; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE0; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_2D; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_MAG_FILTER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_MIN_FILTER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_WRAP_S; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_WRAP_T; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TRIANGLES; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_UNSIGNED_BYTE; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_VERTEX_SHADER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wgetShaderHeader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglActiveTexture; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglAttachShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindAttributeLocation; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindTexture; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBufferData0; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglClear; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglClearColor; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCompileShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteTextures; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDetachShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDisableVertexAttribArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDrawArrays; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglEnableVertexAttribArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglFlush; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGenTextures; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetUniformLocation; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglLinkProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglShaderSource; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglTexImage2D; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglTexParameteri; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform1i; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform2f; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUseProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglVertexAttribPointer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglViewport; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.getCanvasHeight; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.getCanvasWidth; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.updateDisplay; import java.nio.IntBuffer; import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.BufferArrayGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.BufferGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.ProgramGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.ShaderGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.TextureGL; import net.minecraft.src.GLAllocation; public class EarlyLoadScreen { diff --git a/src/main/java/net/lax1dude/eaglercraft/TextureTerrainMap.java b/src/main/java/net/lax1dude/eaglercraft/TextureTerrainMap.java index cf402b0..9db9380 100644 --- a/src/main/java/net/lax1dude/eaglercraft/TextureTerrainMap.java +++ b/src/main/java/net/lax1dude/eaglercraft/TextureTerrainMap.java @@ -5,8 +5,6 @@ import java.nio.ByteOrder; import java.nio.IntBuffer; import java.util.ArrayList; -import net.lax1dude.eaglercraft.EaglerAdapter; -import net.lax1dude.eaglercraft.EaglerImage; import net.minecraft.client.Minecraft; import net.minecraft.src.Block; import net.minecraft.src.GLAllocation; diff --git a/src/main/java/net/lax1dude/eaglercraft/WebsocketNetworkManager.java b/src/main/java/net/lax1dude/eaglercraft/WebsocketNetworkManager.java index 955366e..06ee3cc 100644 --- a/src/main/java/net/lax1dude/eaglercraft/WebsocketNetworkManager.java +++ b/src/main/java/net/lax1dude/eaglercraft/WebsocketNetworkManager.java @@ -1,11 +1,11 @@ package net.lax1dude.eaglercraft; -import java.io.InputStream; import java.io.ByteArrayOutputStream; import java.io.DataInputStream; import java.io.DataOutputStream; import java.io.EOFException; import java.io.IOException; +import java.io.InputStream; import java.nio.ByteBuffer; import java.util.LinkedList; diff --git a/src/main/java/net/lax1dude/eaglercraft/glemu/EaglerAdapterGL30.java b/src/main/java/net/lax1dude/eaglercraft/glemu/EaglerAdapterGL30.java index c5c895f..dbdb91a 100644 --- a/src/main/java/net/lax1dude/eaglercraft/glemu/EaglerAdapterGL30.java +++ b/src/main/java/net/lax1dude/eaglercraft/glemu/EaglerAdapterGL30.java @@ -8,7 +8,6 @@ import java.nio.IntBuffer; import java.util.HashMap; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2; import net.lax1dude.eaglercraft.glemu.vector.Matrix4f; import net.lax1dude.eaglercraft.glemu.vector.Vector3f; diff --git a/src/main/java/net/lax1dude/eaglercraft/glemu/EffectPipeline.java b/src/main/java/net/lax1dude/eaglercraft/glemu/EffectPipeline.java index 4c3b955..3bd168d 100644 --- a/src/main/java/net/lax1dude/eaglercraft/glemu/EffectPipeline.java +++ b/src/main/java/net/lax1dude/eaglercraft/glemu/EffectPipeline.java @@ -1,17 +1,96 @@ package net.lax1dude.eaglercraft.glemu; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_ARRAY_BUFFER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_CLAMP; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_COLOR_ATTACHMENT0; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_CULL_FACE; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_DEPTH24_STENCIL8; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_DEPTH_STENCIL; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_DEPTH_STENCIL_ATTACHMENT; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_DEPTH_TEST; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_FLOAT; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_FRAGMENT_SHADER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_FRAMEBUFFER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_LINEAR; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_NEAREST; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_RGB; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_STATIC_DRAW; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE0; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE1; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE2; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_2D; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_MAG_FILTER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_MIN_FILTER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_WRAP_S; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_WRAP_T; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TRIANGLES; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_UNSIGNED_BYTE; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_UNSIGNED_INT_24_8; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_VERTEX_SHADER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_VIEWPORT; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wgetShaderHeader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglActiveTexture; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglAttachShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindAttributeLocation; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindFramebuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindTexture; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBufferData0; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCompileShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateFramebuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDepthMask; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDetachShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDisable; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDrawArrays; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglEnableVertexAttribArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglFramebufferTexture2D; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGenTextures; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetParameter; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetProgramInfoLog; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetProgramLinked; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetShaderCompiled; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetShaderInfoLog; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetUniformLocation; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglLinkProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglShaderSource; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglTexImage2D; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglTexParameteri; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform1f; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform1i; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform2f; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform2i; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform3f; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniformMat4fv; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUseProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglVertexAttribPointer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglViewport; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.fileContents; +import static net.lax1dude.eaglercraft.glemu.EaglerAdapterGL30.isWebGL; +import static net.lax1dude.eaglercraft.glemu.EaglerAdapterGL30.matProjPointer; +import static net.lax1dude.eaglercraft.glemu.EaglerAdapterGL30.matProjV; + import java.nio.ByteBuffer; import java.nio.ByteOrder; import java.nio.IntBuffer; import java.util.HashMap; import net.lax1dude.eaglercraft.EaglercraftRandom; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.BufferArrayGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.BufferGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.FramebufferGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.ProgramGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.ShaderGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.TextureGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.UniformGL; import net.lax1dude.eaglercraft.glemu.vector.Matrix4f; -import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_CULL_FACE; -import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDisable; -import static net.lax1dude.eaglercraft.glemu.EaglerAdapterGL30.*; - public class EffectPipeline { private static String[] pipeline_tmp = null; diff --git a/src/main/java/net/lax1dude/eaglercraft/glemu/EffectPipelineFXAA.java b/src/main/java/net/lax1dude/eaglercraft/glemu/EffectPipelineFXAA.java index 85fce94..1d26c45 100644 --- a/src/main/java/net/lax1dude/eaglercraft/glemu/EffectPipelineFXAA.java +++ b/src/main/java/net/lax1dude/eaglercraft/glemu/EffectPipelineFXAA.java @@ -1,16 +1,101 @@ package net.lax1dude.eaglercraft.glemu; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_ARRAY_BUFFER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_BACK; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_CLAMP; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_COLOR_ATTACHMENT0; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_COLOR_BUFFER_BIT; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_CULL_FACE; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_DEPTH_ATTACHMENT; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_DEPTH_BUFFER_BIT; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_DEPTH_COMPONENT32F; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_DEPTH_TEST; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_DRAW_FRAMEBUFFER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_FLOAT; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_FRAGMENT_SHADER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_FRAMEBUFFER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_LINE_SMOOTH; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_MULTISAMPLE; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_NEAREST; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_READ_FRAMEBUFFER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_RGB; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_RGB8; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_STATIC_DRAW; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE0; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_2D; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_MAG_FILTER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_MIN_FILTER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_WRAP_S; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TEXTURE_WRAP_T; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_TRIANGLES; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_UNSIGNED_BYTE; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_VERTEX_SHADER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wgetShaderHeader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglActiveTexture; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglAttachShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindFramebuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindRenderbuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindTexture; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBlitFramebuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBufferData0; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglClear; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCompileShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateFramebuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateRenderBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteFramebuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteRenderbuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteTextures; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDepthMask; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDetachShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDisable; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDrawArrays; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDrawBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglEnable; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglEnableVertexAttribArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglFramebufferRenderbuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglFramebufferTexture2D; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGenTextures; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetProgramInfoLog; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetProgramLinked; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetShaderCompiled; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetShaderInfoLog; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetUniformLocation; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglLinkProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglRenderbufferStorage; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglRenderbufferStorageMultisample; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglShaderSource; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglTexImage2D; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglTexParameteri; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform1i; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform2f; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUseProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglVertexAttribPointer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglViewport; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.fileContents; +import static net.lax1dude.eaglercraft.glemu.EaglerAdapterGL30.isWebGL; + import java.nio.ByteBuffer; import java.nio.ByteOrder; import java.nio.IntBuffer; import net.lax1dude.eaglercraft.EaglerAdapter; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.BufferArrayGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.BufferGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.FramebufferGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.ProgramGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.RenderbufferGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.ShaderGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.TextureGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.UniformGL; import net.minecraft.client.Minecraft; -import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_DEPTH_TEST; -import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDisable; -import static net.lax1dude.eaglercraft.glemu.EaglerAdapterGL30.*; - public class EffectPipelineFXAA { private static boolean isUsingFXAA = false; diff --git a/src/main/java/net/lax1dude/eaglercraft/glemu/FixedFunctionShader.java b/src/main/java/net/lax1dude/eaglercraft/glemu/FixedFunctionShader.java index f9352ec..e5c5531 100644 --- a/src/main/java/net/lax1dude/eaglercraft/glemu/FixedFunctionShader.java +++ b/src/main/java/net/lax1dude/eaglercraft/glemu/FixedFunctionShader.java @@ -1,12 +1,49 @@ package net.lax1dude.eaglercraft.glemu; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_ARRAY_BUFFER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_FRAGMENT_SHADER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_VERTEX_SHADER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wgetShaderHeader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglAttachShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindAttributeLocation; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCompileShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDetachShader; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglEnableVertexAttribArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetProgramInfoLog; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetProgramLinked; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetShaderCompiled; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetShaderInfoLog; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglGetUniformLocation; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglLinkProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglShaderSource; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform1f; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform1i; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform2f; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform3f; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniform4f; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUniformMat4fv; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglUseProgram; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglVertexAttribPointer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.fileContents; + import net.lax1dude.eaglercraft.EaglerAdapter; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.BufferArrayGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.BufferGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.ProgramGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.ShaderGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.UniformGL; import net.lax1dude.eaglercraft.glemu.vector.Matrix4f; import net.lax1dude.eaglercraft.glemu.vector.Vector2f; import net.lax1dude.eaglercraft.glemu.vector.Vector4f; -import static net.lax1dude.eaglercraft.glemu.EaglerAdapterGL30.*; - public class FixedFunctionShader { private static final FixedFunctionShader[] instances = new FixedFunctionShader[4096]; //lol diff --git a/src/main/java/net/lax1dude/eaglercraft/glemu/HighPolyMesh.java b/src/main/java/net/lax1dude/eaglercraft/glemu/HighPolyMesh.java index 1794067..462c57c 100644 --- a/src/main/java/net/lax1dude/eaglercraft/glemu/HighPolyMesh.java +++ b/src/main/java/net/lax1dude/eaglercraft/glemu/HighPolyMesh.java @@ -1,19 +1,32 @@ package net.lax1dude.eaglercraft.glemu; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_ARRAY_BUFFER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_ELEMENT_ARRAY_BUFFER; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_FLOAT; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_STATIC_DRAW; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wGL_UNSIGNED_BYTE; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBindVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglBufferData0; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglCreateVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteBuffer; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglDeleteVertexArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglEnableVertexAttribArray; +import static net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2._wglVertexAttribPointer; + import java.io.ByteArrayInputStream; import java.io.DataInputStream; import java.io.EOFException; import java.io.IOException; -import java.nio.ByteBuffer; -import java.nio.ByteOrder; import java.nio.IntBuffer; import java.nio.charset.StandardCharsets; import java.util.Arrays; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.BufferArrayGL; +import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.BufferGL; import net.minecraft.src.GLAllocation; -import static net.lax1dude.eaglercraft.EaglerAdapter.*; - public class HighPolyMesh { final BufferArrayGL vertexArray; diff --git a/src/main/java/net/minecraft/client/Minecraft.java b/src/main/java/net/minecraft/client/Minecraft.java index df7f7c6..1c635d9 100644 --- a/src/main/java/net/minecraft/client/Minecraft.java +++ b/src/main/java/net/minecraft/client/Minecraft.java @@ -7,17 +7,77 @@ import java.util.List; import net.lax1dude.eaglercraft.DefaultSkinRenderer; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.EaglerProfile; - import net.lax1dude.eaglercraft.GuiScreenEditProfile; import net.lax1dude.eaglercraft.GuiScreenLicense; import net.lax1dude.eaglercraft.GuiVoiceOverlay; import net.lax1dude.eaglercraft.LocalStorageManager; import net.lax1dude.eaglercraft.Voice; -import net.minecraft.src.*; - import net.lax1dude.eaglercraft.adapter.Tessellator; import net.lax1dude.eaglercraft.glemu.EffectPipeline; import net.lax1dude.eaglercraft.glemu.FixedFunctionShader; +import net.minecraft.src.AchievementList; +import net.minecraft.src.AxisAlignedBB; +import net.minecraft.src.Block; +import net.minecraft.src.ChatAllowedCharacters; +import net.minecraft.src.ColorizerFoliage; +import net.minecraft.src.ColorizerGrass; +import net.minecraft.src.EffectRenderer; +import net.minecraft.src.EntityBoat; +import net.minecraft.src.EntityClientPlayerMP; +import net.minecraft.src.EntityItemFrame; +import net.minecraft.src.EntityList; +import net.minecraft.src.EntityLiving; +import net.minecraft.src.EntityMinecart; +import net.minecraft.src.EntityPainting; +import net.minecraft.src.EntityPlayer; +import net.minecraft.src.EntityRenderer; +import net.minecraft.src.EnumChatFormatting; +import net.minecraft.src.EnumMovingObjectType; +import net.minecraft.src.EnumOS; +import net.minecraft.src.EnumOptions; +import net.minecraft.src.FontRenderer; +import net.minecraft.src.GLAllocation; +import net.minecraft.src.GameSettings; +import net.minecraft.src.GuiAchievement; +import net.minecraft.src.GuiChat; +import net.minecraft.src.GuiConnecting; +import net.minecraft.src.GuiGameOver; +import net.minecraft.src.GuiIngame; +import net.minecraft.src.GuiIngameMenu; +import net.minecraft.src.GuiInventory; +import net.minecraft.src.GuiMainMenu; +import net.minecraft.src.GuiMultiplayer; +import net.minecraft.src.GuiScreen; +import net.minecraft.src.GuiSleepMP; +import net.minecraft.src.INetworkManager; +import net.minecraft.src.Item; +import net.minecraft.src.ItemRenderer; +import net.minecraft.src.ItemStack; +import net.minecraft.src.KeyBinding; +import net.minecraft.src.LoadingScreenRenderer; +import net.minecraft.src.MathHelper; +import net.minecraft.src.MouseHelper; +import net.minecraft.src.MovementInputFromOptions; +import net.minecraft.src.MovingObjectPosition; +import net.minecraft.src.NetClientHandler; +import net.minecraft.src.OpenGlHelper; +import net.minecraft.src.Packet3Chat; +import net.minecraft.src.PlayerControllerMP; +import net.minecraft.src.Profiler; +import net.minecraft.src.ProfilerResult; +import net.minecraft.src.RenderBlocks; +import net.minecraft.src.RenderEngine; +import net.minecraft.src.RenderGlobal; +import net.minecraft.src.RenderManager; +import net.minecraft.src.ScaledResolution; +import net.minecraft.src.ServerData; +import net.minecraft.src.SoundManager; +import net.minecraft.src.StatStringFormatKeyInv; +import net.minecraft.src.StringTranslate; +import net.minecraft.src.TextureManager; +import net.minecraft.src.TexturePackList; +import net.minecraft.src.Timer; +import net.minecraft.src.WorldClient; public class Minecraft implements Runnable { diff --git a/src/main/java/net/minecraft/src/ActiveRenderInfo.java b/src/main/java/net/minecraft/src/ActiveRenderInfo.java index 54a4964..19c63a0 100644 --- a/src/main/java/net/minecraft/src/ActiveRenderInfo.java +++ b/src/main/java/net/minecraft/src/ActiveRenderInfo.java @@ -1,7 +1,6 @@ package net.minecraft.src; import java.nio.FloatBuffer; -import java.nio.IntBuffer; import net.lax1dude.eaglercraft.EaglerAdapter; diff --git a/src/main/java/net/minecraft/src/ContainerEnchantment.java b/src/main/java/net/minecraft/src/ContainerEnchantment.java index bc617d7..e1ee379 100644 --- a/src/main/java/net/minecraft/src/ContainerEnchantment.java +++ b/src/main/java/net/minecraft/src/ContainerEnchantment.java @@ -1,7 +1,5 @@ package net.minecraft.src; -import java.util.List; - import net.lax1dude.eaglercraft.EaglercraftRandom; public class ContainerEnchantment extends Container { diff --git a/src/main/java/net/minecraft/src/CreativeCrafting.java b/src/main/java/net/minecraft/src/CreativeCrafting.java index e3c5f12..006139d 100644 --- a/src/main/java/net/minecraft/src/CreativeCrafting.java +++ b/src/main/java/net/minecraft/src/CreativeCrafting.java @@ -1,6 +1,7 @@ package net.minecraft.src; import java.util.List; + import net.minecraft.client.Minecraft; public class CreativeCrafting implements ICrafting { diff --git a/src/main/java/net/minecraft/src/EntityBoat.java b/src/main/java/net/minecraft/src/EntityBoat.java index 41deaac..23dd7ae 100644 --- a/src/main/java/net/minecraft/src/EntityBoat.java +++ b/src/main/java/net/minecraft/src/EntityBoat.java @@ -1,9 +1,5 @@ package net.minecraft.src; -import java.util.List; - - - public class EntityBoat extends Entity { private boolean field_70279_a; private double speedMultiplier; diff --git a/src/main/java/net/minecraft/src/EntityLightningBolt.java b/src/main/java/net/minecraft/src/EntityLightningBolt.java index feee0a2..4f65d14 100644 --- a/src/main/java/net/minecraft/src/EntityLightningBolt.java +++ b/src/main/java/net/minecraft/src/EntityLightningBolt.java @@ -1,7 +1,5 @@ package net.minecraft.src; -import java.util.List; - public class EntityLightningBolt extends EntityWeatherEffect { /** * Declares which state the lightning bolt is in. Whether it's in the air, hit diff --git a/src/main/java/net/minecraft/src/EntityMinecart.java b/src/main/java/net/minecraft/src/EntityMinecart.java index 49ac0a6..55d301d 100644 --- a/src/main/java/net/minecraft/src/EntityMinecart.java +++ b/src/main/java/net/minecraft/src/EntityMinecart.java @@ -1,9 +1,5 @@ package net.minecraft.src; -import java.util.List; - - - public abstract class EntityMinecart extends Entity { private boolean isInReverse; private IUpdatePlayerListBox field_82344_g; diff --git a/src/main/java/net/minecraft/src/EntityPlayer.java b/src/main/java/net/minecraft/src/EntityPlayer.java index e816e44..a45c8bd 100644 --- a/src/main/java/net/minecraft/src/EntityPlayer.java +++ b/src/main/java/net/minecraft/src/EntityPlayer.java @@ -5,7 +5,6 @@ import java.util.Iterator; import java.util.List; import net.lax1dude.eaglercraft.DefaultSkinRenderer; - import net.minecraft.client.Minecraft; public abstract class EntityPlayer extends EntityLiving implements ICommandSender { diff --git a/src/main/java/net/minecraft/src/EntityPotion.java b/src/main/java/net/minecraft/src/EntityPotion.java index b83125f..9414893 100644 --- a/src/main/java/net/minecraft/src/EntityPotion.java +++ b/src/main/java/net/minecraft/src/EntityPotion.java @@ -1,10 +1,5 @@ package net.minecraft.src; -import java.util.Iterator; -import java.util.List; - - - public class EntityPotion extends EntityThrowable { /** * The damage value of the thrown potion that this EntityPotion represents. diff --git a/src/main/java/net/minecraft/src/EntityRenderer.java b/src/main/java/net/minecraft/src/EntityRenderer.java index 8246e74..7be99a5 100644 --- a/src/main/java/net/minecraft/src/EntityRenderer.java +++ b/src/main/java/net/minecraft/src/EntityRenderer.java @@ -3,14 +3,13 @@ package net.minecraft.src; import java.nio.FloatBuffer; import java.util.List; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.EaglerImage; import net.lax1dude.eaglercraft.EaglercraftRandom; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; -import net.lax1dude.eaglercraft.glemu.EffectPipeline; import net.lax1dude.eaglercraft.glemu.EffectPipelineFXAA; +import net.minecraft.client.Minecraft; public class EntityRenderer { public static boolean anaglyphEnable = false; diff --git a/src/main/java/net/minecraft/src/EntityThrowable.java b/src/main/java/net/minecraft/src/EntityThrowable.java index 91a646a..3931476 100644 --- a/src/main/java/net/minecraft/src/EntityThrowable.java +++ b/src/main/java/net/minecraft/src/EntityThrowable.java @@ -1,9 +1,5 @@ package net.minecraft.src; -import java.util.List; - - - public abstract class EntityThrowable extends Entity implements IProjectile { private int xTile = -1; private int yTile = -1; diff --git a/src/main/java/net/minecraft/src/EntityWitch.java b/src/main/java/net/minecraft/src/EntityWitch.java index bc90811..5c0d308 100644 --- a/src/main/java/net/minecraft/src/EntityWitch.java +++ b/src/main/java/net/minecraft/src/EntityWitch.java @@ -1,8 +1,5 @@ package net.minecraft.src; -import java.util.Iterator; -import java.util.List; - public class EntityWitch extends EntityMob implements IRangedAttackMob { /** List of items a witch should drop on death. */ private static final int[] witchDrops = new int[] { Item.lightStoneDust.itemID, Item.sugar.itemID, Item.redstone.itemID, Item.spiderEye.itemID, Item.glassBottle.itemID, Item.gunpowder.itemID, Item.stick.itemID, Item.stick.itemID }; diff --git a/src/main/java/net/minecraft/src/GLAllocation.java b/src/main/java/net/minecraft/src/GLAllocation.java index 3908bf2..1d063b1 100644 --- a/src/main/java/net/minecraft/src/GLAllocation.java +++ b/src/main/java/net/minecraft/src/GLAllocation.java @@ -11,7 +11,6 @@ import java.util.List; import java.util.Map; import java.util.Map.Entry; -import net.lax1dude.eaglercraft.ConfigConstants; import net.lax1dude.eaglercraft.EaglerAdapter; public class GLAllocation { diff --git a/src/main/java/net/minecraft/src/GuiAchievement.java b/src/main/java/net/minecraft/src/GuiAchievement.java index f563933..7ca4191 100644 --- a/src/main/java/net/minecraft/src/GuiAchievement.java +++ b/src/main/java/net/minecraft/src/GuiAchievement.java @@ -1,8 +1,8 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; +import net.minecraft.client.Minecraft; public class GuiAchievement extends Gui { /** Holds the instance of the game (Minecraft) */ diff --git a/src/main/java/net/minecraft/src/GuiBeaconButton.java b/src/main/java/net/minecraft/src/GuiBeaconButton.java index f9a0dd3..e7a401c 100644 --- a/src/main/java/net/minecraft/src/GuiBeaconButton.java +++ b/src/main/java/net/minecraft/src/GuiBeaconButton.java @@ -1,8 +1,8 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; +import net.minecraft.client.Minecraft; class GuiBeaconButton extends GuiButton { /** Texture for this button. */ diff --git a/src/main/java/net/minecraft/src/GuiButton.java b/src/main/java/net/minecraft/src/GuiButton.java index 94e8dbf..780604c 100644 --- a/src/main/java/net/minecraft/src/GuiButton.java +++ b/src/main/java/net/minecraft/src/GuiButton.java @@ -1,8 +1,8 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; +import net.minecraft.client.Minecraft; public class GuiButton extends Gui { /** Button width in pixels */ diff --git a/src/main/java/net/minecraft/src/GuiButtonLanguage.java b/src/main/java/net/minecraft/src/GuiButtonLanguage.java index b984024..97f6575 100644 --- a/src/main/java/net/minecraft/src/GuiButtonLanguage.java +++ b/src/main/java/net/minecraft/src/GuiButtonLanguage.java @@ -1,8 +1,8 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; +import net.minecraft.client.Minecraft; public class GuiButtonLanguage extends GuiButton { public GuiButtonLanguage(int par1, int par2, int par3) { diff --git a/src/main/java/net/minecraft/src/GuiButtonMerchant.java b/src/main/java/net/minecraft/src/GuiButtonMerchant.java index 1909650..c7efe4e 100644 --- a/src/main/java/net/minecraft/src/GuiButtonMerchant.java +++ b/src/main/java/net/minecraft/src/GuiButtonMerchant.java @@ -1,8 +1,8 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; +import net.minecraft.client.Minecraft; class GuiButtonMerchant extends GuiButton { /** diff --git a/src/main/java/net/minecraft/src/GuiButtonNextPage.java b/src/main/java/net/minecraft/src/GuiButtonNextPage.java index c88d630..0982575 100644 --- a/src/main/java/net/minecraft/src/GuiButtonNextPage.java +++ b/src/main/java/net/minecraft/src/GuiButtonNextPage.java @@ -1,8 +1,8 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; +import net.minecraft.client.Minecraft; class GuiButtonNextPage extends GuiButton { /** diff --git a/src/main/java/net/minecraft/src/GuiContainer.java b/src/main/java/net/minecraft/src/GuiContainer.java index cd1ba24..c5ccfe6 100644 --- a/src/main/java/net/minecraft/src/GuiContainer.java +++ b/src/main/java/net/minecraft/src/GuiContainer.java @@ -5,9 +5,10 @@ import java.util.HashSet; import java.util.Iterator; import java.util.List; import java.util.Set; -import net.minecraft.client.Minecraft; + import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; +import net.minecraft.client.Minecraft; public abstract class GuiContainer extends GuiScreen { /** Stacks renderer. Icons, stack size, health, etc... */ diff --git a/src/main/java/net/minecraft/src/GuiIngame.java b/src/main/java/net/minecraft/src/GuiIngame.java index bb4e67d..e2e4e21 100644 --- a/src/main/java/net/minecraft/src/GuiIngame.java +++ b/src/main/java/net/minecraft/src/GuiIngame.java @@ -4,7 +4,6 @@ import java.util.Collection; import java.util.Iterator; import java.util.List; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.ConfigConstants; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.EaglercraftRandom; @@ -12,6 +11,7 @@ import net.lax1dude.eaglercraft.EnumBrowser; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; import net.lax1dude.eaglercraft.glemu.EffectPipeline; +import net.minecraft.client.Minecraft; public class GuiIngame extends Gui { private static RenderItem itemRenderer = null; diff --git a/src/main/java/net/minecraft/src/GuiInventory.java b/src/main/java/net/minecraft/src/GuiInventory.java index 6b4a116..d008dce 100644 --- a/src/main/java/net/minecraft/src/GuiInventory.java +++ b/src/main/java/net/minecraft/src/GuiInventory.java @@ -1,9 +1,8 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.TextureLocation; +import net.minecraft.client.Minecraft; public class GuiInventory extends InventoryEffectRenderer { /** diff --git a/src/main/java/net/minecraft/src/GuiNewChat.java b/src/main/java/net/minecraft/src/GuiNewChat.java index 7fa8975..f8ba269 100644 --- a/src/main/java/net/minecraft/src/GuiNewChat.java +++ b/src/main/java/net/minecraft/src/GuiNewChat.java @@ -5,7 +5,6 @@ import java.util.Iterator; import java.util.List; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.minecraft.client.Minecraft; public class GuiNewChat extends Gui { diff --git a/src/main/java/net/minecraft/src/GuiParticle.java b/src/main/java/net/minecraft/src/GuiParticle.java index 818aaba..27a3962 100644 --- a/src/main/java/net/minecraft/src/GuiParticle.java +++ b/src/main/java/net/minecraft/src/GuiParticle.java @@ -2,9 +2,10 @@ package net.minecraft.src; import java.util.ArrayList; import java.util.List; -import net.minecraft.client.Minecraft; + import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; +import net.minecraft.client.Minecraft; public class GuiParticle extends Gui { private List particles = new ArrayList(); diff --git a/src/main/java/net/minecraft/src/GuiRepair.java b/src/main/java/net/minecraft/src/GuiRepair.java index 15f759b..0f7392c 100644 --- a/src/main/java/net/minecraft/src/GuiRepair.java +++ b/src/main/java/net/minecraft/src/GuiRepair.java @@ -1,9 +1,10 @@ package net.minecraft.src; import java.util.List; -import net.minecraft.client.Minecraft; + import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; +import net.minecraft.client.Minecraft; public class GuiRepair extends GuiContainer implements ICrafting { private ContainerRepair repairContainer; diff --git a/src/main/java/net/minecraft/src/GuiScreen.java b/src/main/java/net/minecraft/src/GuiScreen.java index 1b3241e..27c4ff4 100644 --- a/src/main/java/net/minecraft/src/GuiScreen.java +++ b/src/main/java/net/minecraft/src/GuiScreen.java @@ -2,10 +2,11 @@ package net.minecraft.src; import java.util.ArrayList; import java.util.List; -import net.minecraft.client.Minecraft; + import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; +import net.minecraft.client.Minecraft; public class GuiScreen extends Gui { public static final boolean isMacOs = Minecraft.getOs() == EnumOS.MACOS; diff --git a/src/main/java/net/minecraft/src/GuiSlot.java b/src/main/java/net/minecraft/src/GuiSlot.java index 0830a21..daebfb3 100644 --- a/src/main/java/net/minecraft/src/GuiSlot.java +++ b/src/main/java/net/minecraft/src/GuiSlot.java @@ -1,10 +1,11 @@ package net.minecraft.src; import java.util.List; -import net.minecraft.client.Minecraft; + import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; +import net.minecraft.client.Minecraft; public abstract class GuiSlot { protected final Minecraft mc; diff --git a/src/main/java/net/minecraft/src/GuiSlotServer.java b/src/main/java/net/minecraft/src/GuiSlotServer.java index 4e7b71e..ce329f7 100644 --- a/src/main/java/net/minecraft/src/GuiSlotServer.java +++ b/src/main/java/net/minecraft/src/GuiSlotServer.java @@ -1,9 +1,9 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; +import net.minecraft.client.Minecraft; class GuiSlotServer extends GuiSlot { /** Instance to the GUI this list is on. */ diff --git a/src/main/java/net/minecraft/src/GuiTextField.java b/src/main/java/net/minecraft/src/GuiTextField.java index 6388244..47fa31f 100644 --- a/src/main/java/net/minecraft/src/GuiTextField.java +++ b/src/main/java/net/minecraft/src/GuiTextField.java @@ -1,7 +1,6 @@ package net.minecraft.src; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.adapter.Tessellator; public class GuiTextField extends Gui { diff --git a/src/main/java/net/minecraft/src/ItemRenderer.java b/src/main/java/net/minecraft/src/ItemRenderer.java index 71359ae..2e53213 100644 --- a/src/main/java/net/minecraft/src/ItemRenderer.java +++ b/src/main/java/net/minecraft/src/ItemRenderer.java @@ -1,10 +1,9 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; +import net.minecraft.client.Minecraft; public class ItemRenderer { /** A reference to the Minecraft object. */ diff --git a/src/main/java/net/minecraft/src/LoadingScreenRenderer.java b/src/main/java/net/minecraft/src/LoadingScreenRenderer.java index b34c659..8acf604 100644 --- a/src/main/java/net/minecraft/src/LoadingScreenRenderer.java +++ b/src/main/java/net/minecraft/src/LoadingScreenRenderer.java @@ -1,9 +1,9 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; +import net.minecraft.client.Minecraft; public class LoadingScreenRenderer implements IProgressUpdate { private String field_73727_a = ""; diff --git a/src/main/java/net/minecraft/src/ModelRenderer.java b/src/main/java/net/minecraft/src/ModelRenderer.java index f8d9614..3ca1f6e 100644 --- a/src/main/java/net/minecraft/src/ModelRenderer.java +++ b/src/main/java/net/minecraft/src/ModelRenderer.java @@ -4,7 +4,6 @@ import java.util.ArrayList; import java.util.List; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.adapter.Tessellator; public class ModelRenderer { diff --git a/src/main/java/net/minecraft/src/NetClientHandler.java b/src/main/java/net/minecraft/src/NetClientHandler.java index f4a6b56..c3535a1 100644 --- a/src/main/java/net/minecraft/src/NetClientHandler.java +++ b/src/main/java/net/minecraft/src/NetClientHandler.java @@ -10,7 +10,11 @@ import java.util.List; import java.util.Map; import java.util.function.Consumer; -import net.lax1dude.eaglercraft.*; +import net.lax1dude.eaglercraft.DefaultSkinRenderer; +import net.lax1dude.eaglercraft.EaglerAdapter; +import net.lax1dude.eaglercraft.EaglercraftRandom; +import net.lax1dude.eaglercraft.Voice; +import net.lax1dude.eaglercraft.WebsocketNetworkManager; import net.lax1dude.eaglercraft.adapter.EaglerAdapterImpl2.RateLimit; import net.minecraft.client.Minecraft; diff --git a/src/main/java/net/minecraft/src/Packet.java b/src/main/java/net/minecraft/src/Packet.java index d6ceb7b..0113147 100644 --- a/src/main/java/net/minecraft/src/Packet.java +++ b/src/main/java/net/minecraft/src/Packet.java @@ -2,7 +2,6 @@ package net.minecraft.src; import java.io.DataInputStream; import java.io.DataOutputStream; -import java.io.EOFException; import java.io.IOException; import java.util.HashMap; import java.util.HashSet; diff --git a/src/main/java/net/minecraft/src/RenderBlocks.java b/src/main/java/net/minecraft/src/RenderBlocks.java index f047ce3..6f6cd0c 100644 --- a/src/main/java/net/minecraft/src/RenderBlocks.java +++ b/src/main/java/net/minecraft/src/RenderBlocks.java @@ -1,7 +1,6 @@ package net.minecraft.src; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.adapter.Tessellator; import net.minecraft.client.Minecraft; diff --git a/src/main/java/net/minecraft/src/RenderEnchantmentTable.java b/src/main/java/net/minecraft/src/RenderEnchantmentTable.java index 55e5c25..c1c8c31 100644 --- a/src/main/java/net/minecraft/src/RenderEnchantmentTable.java +++ b/src/main/java/net/minecraft/src/RenderEnchantmentTable.java @@ -1,7 +1,6 @@ package net.minecraft.src; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.TextureLocation; public class RenderEnchantmentTable extends TileEntitySpecialRenderer { diff --git a/src/main/java/net/minecraft/src/RenderEndPortal.java b/src/main/java/net/minecraft/src/RenderEndPortal.java index 93f7a91..752119d 100644 --- a/src/main/java/net/minecraft/src/RenderEndPortal.java +++ b/src/main/java/net/minecraft/src/RenderEndPortal.java @@ -1,11 +1,12 @@ package net.minecraft.src; import java.nio.FloatBuffer; -import net.minecraft.client.Minecraft; + import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.EaglercraftRandom; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; +import net.minecraft.client.Minecraft; public class RenderEndPortal extends TileEntitySpecialRenderer { FloatBuffer field_76908_a = GLAllocation.createDirectFloatBuffer(16); diff --git a/src/main/java/net/minecraft/src/RenderEngine.java b/src/main/java/net/minecraft/src/RenderEngine.java index d3142d9..d3bf3f2 100644 --- a/src/main/java/net/minecraft/src/RenderEngine.java +++ b/src/main/java/net/minecraft/src/RenderEngine.java @@ -1,18 +1,16 @@ package net.minecraft.src; import java.io.IOException; -import java.io.InputStream; -import java.nio.ByteBuffer; -import java.nio.ByteOrder; import java.nio.IntBuffer; import java.util.HashMap; import java.util.Iterator; import java.util.Map; -import net.minecraft.client.Minecraft; + import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.EaglerImage; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.TextureTerrainMap; +import net.minecraft.client.Minecraft; public class RenderEngine { private HashMap textureMap = new HashMap(); diff --git a/src/main/java/net/minecraft/src/RenderFish.java b/src/main/java/net/minecraft/src/RenderFish.java index 6b538c9..4af1b2f 100644 --- a/src/main/java/net/minecraft/src/RenderFish.java +++ b/src/main/java/net/minecraft/src/RenderFish.java @@ -1,10 +1,9 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; +import net.minecraft.client.Minecraft; public class RenderFish extends Render { diff --git a/src/main/java/net/minecraft/src/RenderGlobal.java b/src/main/java/net/minecraft/src/RenderGlobal.java index c64fc7b..37bca6e 100644 --- a/src/main/java/net/minecraft/src/RenderGlobal.java +++ b/src/main/java/net/minecraft/src/RenderGlobal.java @@ -1,6 +1,5 @@ package net.minecraft.src; -import java.nio.IntBuffer; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; @@ -9,11 +8,11 @@ import java.util.Iterator; import java.util.List; import java.util.Map; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.EaglercraftRandom; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; +import net.minecraft.client.Minecraft; public class RenderGlobal implements IWorldAccess { public List tileEntities = new ArrayList(); diff --git a/src/main/java/net/minecraft/src/RenderIronGolem.java b/src/main/java/net/minecraft/src/RenderIronGolem.java index 877be60..85b6a92 100644 --- a/src/main/java/net/minecraft/src/RenderIronGolem.java +++ b/src/main/java/net/minecraft/src/RenderIronGolem.java @@ -1,7 +1,6 @@ package net.minecraft.src; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.TextureLocation; public class RenderIronGolem extends RenderLiving { diff --git a/src/main/java/net/minecraft/src/RenderItem.java b/src/main/java/net/minecraft/src/RenderItem.java index 3dd367c..14ac8aa 100644 --- a/src/main/java/net/minecraft/src/RenderItem.java +++ b/src/main/java/net/minecraft/src/RenderItem.java @@ -1,10 +1,10 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.EaglercraftRandom; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; +import net.minecraft.client.Minecraft; public class RenderItem extends Render { private RenderBlocks itemRenderBlocks = new RenderBlocks(); diff --git a/src/main/java/net/minecraft/src/RenderLiving.java b/src/main/java/net/minecraft/src/RenderLiving.java index 6154541..35b0b56 100644 --- a/src/main/java/net/minecraft/src/RenderLiving.java +++ b/src/main/java/net/minecraft/src/RenderLiving.java @@ -1,12 +1,12 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; -import net.lax1dude.eaglercraft.TextureLocation; -import net.lax1dude.eaglercraft.Voice; -import net.lax1dude.eaglercraft.adapter.Tessellator; import net.lax1dude.eaglercraft.DefaultSkinRenderer; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.EaglercraftRandom; +import net.lax1dude.eaglercraft.TextureLocation; +import net.lax1dude.eaglercraft.Voice; +import net.lax1dude.eaglercraft.adapter.Tessellator; +import net.minecraft.client.Minecraft; public abstract class RenderLiving extends Render { diff --git a/src/main/java/net/minecraft/src/RenderMagmaCube.java b/src/main/java/net/minecraft/src/RenderMagmaCube.java index 4d1b9e3..35a35b4 100644 --- a/src/main/java/net/minecraft/src/RenderMagmaCube.java +++ b/src/main/java/net/minecraft/src/RenderMagmaCube.java @@ -1,6 +1,5 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; diff --git a/src/main/java/net/minecraft/src/RenderMinecart.java b/src/main/java/net/minecraft/src/RenderMinecart.java index 06d4fd2..f1a9b0d 100644 --- a/src/main/java/net/minecraft/src/RenderMinecart.java +++ b/src/main/java/net/minecraft/src/RenderMinecart.java @@ -1,7 +1,6 @@ package net.minecraft.src; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.TextureLocation; public class RenderMinecart extends Render { diff --git a/src/main/java/net/minecraft/src/RenderPlayer.java b/src/main/java/net/minecraft/src/RenderPlayer.java index af32ef8..df773cf 100644 --- a/src/main/java/net/minecraft/src/RenderPlayer.java +++ b/src/main/java/net/minecraft/src/RenderPlayer.java @@ -1,12 +1,12 @@ package net.minecraft.src; +import net.lax1dude.eaglercraft.DefaultSkinRenderer; +import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.EaglerProfile; import net.lax1dude.eaglercraft.HighPolySkin; import net.lax1dude.eaglercraft.ModelBipedNewSkins; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.glemu.vector.Matrix4f; -import net.lax1dude.eaglercraft.DefaultSkinRenderer; -import net.lax1dude.eaglercraft.EaglerAdapter; import net.minecraft.client.Minecraft; public class RenderPlayer extends RenderLiving { diff --git a/src/main/java/net/minecraft/src/StringTranslate.java b/src/main/java/net/minecraft/src/StringTranslate.java index ef29dc3..89c8bfe 100644 --- a/src/main/java/net/minecraft/src/StringTranslate.java +++ b/src/main/java/net/minecraft/src/StringTranslate.java @@ -3,7 +3,6 @@ package net.minecraft.src; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; -import java.util.Enumeration; import java.util.IllegalFormatException; import java.util.Properties; import java.util.TreeMap; diff --git a/src/main/java/net/minecraft/src/TexturePackList.java b/src/main/java/net/minecraft/src/TexturePackList.java index b793cae..c318b11 100644 --- a/src/main/java/net/minecraft/src/TexturePackList.java +++ b/src/main/java/net/minecraft/src/TexturePackList.java @@ -5,6 +5,7 @@ import java.util.Collections; import java.util.HashMap; import java.util.List; import java.util.Map; + import net.minecraft.client.Minecraft; public class TexturePackList { diff --git a/src/main/java/net/minecraft/src/TextureStitched.java b/src/main/java/net/minecraft/src/TextureStitched.java index 210ca24..7ae57a9 100644 --- a/src/main/java/net/minecraft/src/TextureStitched.java +++ b/src/main/java/net/minecraft/src/TextureStitched.java @@ -1,6 +1,5 @@ package net.minecraft.src; -import java.io.BufferedReader; import java.util.ArrayList; import java.util.List; diff --git a/src/main/java/net/minecraft/src/TileEntityBeacon.java b/src/main/java/net/minecraft/src/TileEntityBeacon.java index 44a3e6b..7aa5b17 100644 --- a/src/main/java/net/minecraft/src/TileEntityBeacon.java +++ b/src/main/java/net/minecraft/src/TileEntityBeacon.java @@ -1,8 +1,5 @@ package net.minecraft.src; -import java.util.Iterator; -import java.util.List; - public class TileEntityBeacon extends TileEntity implements IInventory { /** List of effects that Beacon can apply */ public static final Potion[][] effectsList = new Potion[][] { { Potion.moveSpeed, Potion.digSpeed }, { Potion.resistance, Potion.jump }, { Potion.damageBoost }, { Potion.regeneration } }; diff --git a/src/main/java/net/minecraft/src/TileEntityBeaconRenderer.java b/src/main/java/net/minecraft/src/TileEntityBeaconRenderer.java index 39a8103..01d9254 100644 --- a/src/main/java/net/minecraft/src/TileEntityBeaconRenderer.java +++ b/src/main/java/net/minecraft/src/TileEntityBeaconRenderer.java @@ -1,10 +1,8 @@ package net.minecraft.src; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; -import net.minecraft.client.Minecraft; public class TileEntityBeaconRenderer extends TileEntitySpecialRenderer { diff --git a/src/main/java/net/minecraft/src/TileEntityChest.java b/src/main/java/net/minecraft/src/TileEntityChest.java index bb8c167..adf3511 100644 --- a/src/main/java/net/minecraft/src/TileEntityChest.java +++ b/src/main/java/net/minecraft/src/TileEntityChest.java @@ -1,8 +1,5 @@ package net.minecraft.src; -import java.util.Iterator; -import java.util.List; - public class TileEntityChest extends TileEntity implements IInventory { private ItemStack[] chestContents = new ItemStack[36]; diff --git a/src/main/java/net/minecraft/src/TileEntityChestRenderer.java b/src/main/java/net/minecraft/src/TileEntityChestRenderer.java index 0af1503..d2bd6e7 100644 --- a/src/main/java/net/minecraft/src/TileEntityChestRenderer.java +++ b/src/main/java/net/minecraft/src/TileEntityChestRenderer.java @@ -3,7 +3,6 @@ package net.minecraft.src; import java.util.Calendar; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.TextureLocation; public class TileEntityChestRenderer extends TileEntitySpecialRenderer { diff --git a/src/main/java/net/minecraft/src/TileEntityEnderChestRenderer.java b/src/main/java/net/minecraft/src/TileEntityEnderChestRenderer.java index a54b177..934a726 100644 --- a/src/main/java/net/minecraft/src/TileEntityEnderChestRenderer.java +++ b/src/main/java/net/minecraft/src/TileEntityEnderChestRenderer.java @@ -1,7 +1,6 @@ package net.minecraft.src; import net.lax1dude.eaglercraft.EaglerAdapter; - import net.lax1dude.eaglercraft.TextureLocation; public class TileEntityEnderChestRenderer extends TileEntitySpecialRenderer { diff --git a/src/main/java/net/minecraft/src/TileEntityRendererPiston.java b/src/main/java/net/minecraft/src/TileEntityRendererPiston.java index a7e2fbf..2d99ec2 100644 --- a/src/main/java/net/minecraft/src/TileEntityRendererPiston.java +++ b/src/main/java/net/minecraft/src/TileEntityRendererPiston.java @@ -1,9 +1,9 @@ package net.minecraft.src; -import net.minecraft.client.Minecraft; import net.lax1dude.eaglercraft.EaglerAdapter; import net.lax1dude.eaglercraft.TextureLocation; import net.lax1dude.eaglercraft.adapter.Tessellator; +import net.minecraft.client.Minecraft; public class TileEntityRendererPiston extends TileEntitySpecialRenderer { /** instance of RenderBlocks used to draw the piston base and extension. */ diff --git a/src/main/java/org/json/XML.java b/src/main/java/org/json/XML.java index 9b2ba89..33838a1 100644 --- a/src/main/java/org/json/XML.java +++ b/src/main/java/org/json/XML.java @@ -26,7 +26,6 @@ SOFTWARE. import java.io.Reader; import java.io.StringReader; -import java.lang.reflect.Method; import java.math.BigDecimal; import java.math.BigInteger; import java.util.Iterator; diff --git a/src/teavm/java/net/lax1dude/eaglercraft/adapter/EaglerAdapterImpl2.java b/src/teavm/java/net/lax1dude/eaglercraft/adapter/EaglerAdapterImpl2.java index 7c62632..e60234b 100644 --- a/src/teavm/java/net/lax1dude/eaglercraft/adapter/EaglerAdapterImpl2.java +++ b/src/teavm/java/net/lax1dude/eaglercraft/adapter/EaglerAdapterImpl2.java @@ -1,6 +1,102 @@ package net.lax1dude.eaglercraft.adapter; -import java.io.*; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.ANY_SAMPLES_PASSED; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.DEPTH24_STENCIL8; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.DEPTH_COMPONENT32F; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.DRAW_FRAMEBUFFER; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.QUERY_RESULT; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.QUERY_RESULT_AVAILABLE; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.READ_FRAMEBUFFER; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.RGB8; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.RGBA8; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.TEXTURE_MAX_ANISOTROPY_EXT; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.TEXTURE_MAX_LEVEL; +import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.UNSIGNED_INT_24_8; +import static org.teavm.jso.webgl.WebGLRenderingContext.ARRAY_BUFFER; +import static org.teavm.jso.webgl.WebGLRenderingContext.BACK; +import static org.teavm.jso.webgl.WebGLRenderingContext.BLEND; +import static org.teavm.jso.webgl.WebGLRenderingContext.CLAMP_TO_EDGE; +import static org.teavm.jso.webgl.WebGLRenderingContext.COLOR_ATTACHMENT0; +import static org.teavm.jso.webgl.WebGLRenderingContext.COLOR_BUFFER_BIT; +import static org.teavm.jso.webgl.WebGLRenderingContext.COMPILE_STATUS; +import static org.teavm.jso.webgl.WebGLRenderingContext.CONTEXT_LOST_WEBGL; +import static org.teavm.jso.webgl.WebGLRenderingContext.CULL_FACE; +import static org.teavm.jso.webgl.WebGLRenderingContext.DEPTH_ATTACHMENT; +import static org.teavm.jso.webgl.WebGLRenderingContext.DEPTH_BUFFER_BIT; +import static org.teavm.jso.webgl.WebGLRenderingContext.DEPTH_STENCIL; +import static org.teavm.jso.webgl.WebGLRenderingContext.DEPTH_STENCIL_ATTACHMENT; +import static org.teavm.jso.webgl.WebGLRenderingContext.DEPTH_TEST; +import static org.teavm.jso.webgl.WebGLRenderingContext.DST_ALPHA; +import static org.teavm.jso.webgl.WebGLRenderingContext.DST_COLOR; +import static org.teavm.jso.webgl.WebGLRenderingContext.DYNAMIC_DRAW; +import static org.teavm.jso.webgl.WebGLRenderingContext.ELEMENT_ARRAY_BUFFER; +import static org.teavm.jso.webgl.WebGLRenderingContext.EQUAL; +import static org.teavm.jso.webgl.WebGLRenderingContext.FLOAT; +import static org.teavm.jso.webgl.WebGLRenderingContext.FRAGMENT_SHADER; +import static org.teavm.jso.webgl.WebGLRenderingContext.FRAMEBUFFER; +import static org.teavm.jso.webgl.WebGLRenderingContext.FRAMEBUFFER_COMPLETE; +import static org.teavm.jso.webgl.WebGLRenderingContext.FRAMEBUFFER_INCOMPLETE_ATTACHMENT; +import static org.teavm.jso.webgl.WebGLRenderingContext.FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT; +import static org.teavm.jso.webgl.WebGLRenderingContext.FRONT; +import static org.teavm.jso.webgl.WebGLRenderingContext.FRONT_AND_BACK; +import static org.teavm.jso.webgl.WebGLRenderingContext.GEQUAL; +import static org.teavm.jso.webgl.WebGLRenderingContext.GREATER; +import static org.teavm.jso.webgl.WebGLRenderingContext.INVALID_ENUM; +import static org.teavm.jso.webgl.WebGLRenderingContext.INVALID_OPERATION; +import static org.teavm.jso.webgl.WebGLRenderingContext.INVALID_VALUE; +import static org.teavm.jso.webgl.WebGLRenderingContext.LEQUAL; +import static org.teavm.jso.webgl.WebGLRenderingContext.LESS; +import static org.teavm.jso.webgl.WebGLRenderingContext.LINEAR; +import static org.teavm.jso.webgl.WebGLRenderingContext.LINEAR_MIPMAP_LINEAR; +import static org.teavm.jso.webgl.WebGLRenderingContext.LINEAR_MIPMAP_NEAREST; +import static org.teavm.jso.webgl.WebGLRenderingContext.LINES; +import static org.teavm.jso.webgl.WebGLRenderingContext.LINE_STRIP; +import static org.teavm.jso.webgl.WebGLRenderingContext.LINK_STATUS; +import static org.teavm.jso.webgl.WebGLRenderingContext.NEAREST; +import static org.teavm.jso.webgl.WebGLRenderingContext.NEAREST_MIPMAP_LINEAR; +import static org.teavm.jso.webgl.WebGLRenderingContext.NEAREST_MIPMAP_NEAREST; +import static org.teavm.jso.webgl.WebGLRenderingContext.ONE; +import static org.teavm.jso.webgl.WebGLRenderingContext.ONE_MINUS_DST_COLOR; +import static org.teavm.jso.webgl.WebGLRenderingContext.ONE_MINUS_SRC_ALPHA; +import static org.teavm.jso.webgl.WebGLRenderingContext.ONE_MINUS_SRC_COLOR; +import static org.teavm.jso.webgl.WebGLRenderingContext.OUT_OF_MEMORY; +import static org.teavm.jso.webgl.WebGLRenderingContext.PACK_ALIGNMENT; +import static org.teavm.jso.webgl.WebGLRenderingContext.POLYGON_OFFSET_FILL; +import static org.teavm.jso.webgl.WebGLRenderingContext.RENDERBUFFER; +import static org.teavm.jso.webgl.WebGLRenderingContext.REPEAT; +import static org.teavm.jso.webgl.WebGLRenderingContext.RGB; +import static org.teavm.jso.webgl.WebGLRenderingContext.RGBA; +import static org.teavm.jso.webgl.WebGLRenderingContext.SHORT; +import static org.teavm.jso.webgl.WebGLRenderingContext.SRC_ALPHA; +import static org.teavm.jso.webgl.WebGLRenderingContext.SRC_COLOR; +import static org.teavm.jso.webgl.WebGLRenderingContext.STATIC_DRAW; +import static org.teavm.jso.webgl.WebGLRenderingContext.TEXTURE0; +import static org.teavm.jso.webgl.WebGLRenderingContext.TEXTURE1; +import static org.teavm.jso.webgl.WebGLRenderingContext.TEXTURE2; +import static org.teavm.jso.webgl.WebGLRenderingContext.TEXTURE3; +import static org.teavm.jso.webgl.WebGLRenderingContext.TEXTURE_2D; +import static org.teavm.jso.webgl.WebGLRenderingContext.TEXTURE_MAG_FILTER; +import static org.teavm.jso.webgl.WebGLRenderingContext.TEXTURE_MIN_FILTER; +import static org.teavm.jso.webgl.WebGLRenderingContext.TEXTURE_WRAP_S; +import static org.teavm.jso.webgl.WebGLRenderingContext.TEXTURE_WRAP_T; +import static org.teavm.jso.webgl.WebGLRenderingContext.TRIANGLES; +import static org.teavm.jso.webgl.WebGLRenderingContext.TRIANGLE_FAN; +import static org.teavm.jso.webgl.WebGLRenderingContext.TRIANGLE_STRIP; +import static org.teavm.jso.webgl.WebGLRenderingContext.UNPACK_ALIGNMENT; +import static org.teavm.jso.webgl.WebGLRenderingContext.UNSIGNED_BYTE; +import static org.teavm.jso.webgl.WebGLRenderingContext.UNSIGNED_INT; +import static org.teavm.jso.webgl.WebGLRenderingContext.UNSIGNED_SHORT; +import static org.teavm.jso.webgl.WebGLRenderingContext.VERTEX_SHADER; +import static org.teavm.jso.webgl.WebGLRenderingContext.VIEWPORT; +import static org.teavm.jso.webgl.WebGLRenderingContext.ZERO; + +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.DataInputStream; +import java.io.DataOutputStream; +import java.io.EOFException; +import java.io.IOException; +import java.io.InputStream; import java.nio.ByteBuffer; import java.nio.IntBuffer; import java.nio.charset.Charset; @@ -17,7 +113,6 @@ import java.util.Set; import java.util.function.Consumer; import java.util.stream.Collectors; -import net.lax1dude.eaglercraft.*; import org.json.JSONObject; import org.teavm.interop.Async; import org.teavm.interop.AsyncCallback; @@ -37,7 +132,11 @@ import org.teavm.jso.dom.events.KeyboardEvent; import org.teavm.jso.dom.events.MessageEvent; import org.teavm.jso.dom.events.MouseEvent; import org.teavm.jso.dom.events.WheelEvent; -import org.teavm.jso.dom.html.*; +import org.teavm.jso.dom.html.HTMLCanvasElement; +import org.teavm.jso.dom.html.HTMLDocument; +import org.teavm.jso.dom.html.HTMLElement; +import org.teavm.jso.dom.html.HTMLImageElement; +import org.teavm.jso.dom.html.HTMLVideoElement; import org.teavm.jso.media.MediaError; import org.teavm.jso.typedarrays.ArrayBuffer; import org.teavm.jso.typedarrays.DataView; @@ -45,7 +144,19 @@ import org.teavm.jso.typedarrays.Float32Array; import org.teavm.jso.typedarrays.Int32Array; import org.teavm.jso.typedarrays.Uint8Array; import org.teavm.jso.typedarrays.Uint8ClampedArray; -import org.teavm.jso.webaudio.*; +import org.teavm.jso.webaudio.AnalyserNode; +import org.teavm.jso.webaudio.AudioBuffer; +import org.teavm.jso.webaudio.AudioBufferSourceNode; +import org.teavm.jso.webaudio.AudioContext; +import org.teavm.jso.webaudio.AudioListener; +import org.teavm.jso.webaudio.DecodeErrorCallback; +import org.teavm.jso.webaudio.DecodeSuccessCallback; +import org.teavm.jso.webaudio.GainNode; +import org.teavm.jso.webaudio.MediaElementAudioSourceNode; +import org.teavm.jso.webaudio.MediaEvent; +import org.teavm.jso.webaudio.MediaStream; +import org.teavm.jso.webaudio.MediaStreamAudioSourceNode; +import org.teavm.jso.webaudio.PannerNode; import org.teavm.jso.webgl.WebGLBuffer; import org.teavm.jso.webgl.WebGLFramebuffer; import org.teavm.jso.webgl.WebGLProgram; @@ -56,13 +167,20 @@ import org.teavm.jso.webgl.WebGLUniformLocation; import org.teavm.jso.websocket.CloseEvent; import org.teavm.jso.websocket.WebSocket; -import net.lax1dude.eaglercraft.adapter.teavm.WebGLQuery; -import net.lax1dude.eaglercraft.adapter.teavm.WebGLVertexArray; -import net.minecraft.src.MathHelper; +import net.lax1dude.eaglercraft.AssetRepository; +import net.lax1dude.eaglercraft.Base64; +import net.lax1dude.eaglercraft.EaglerImage; +import net.lax1dude.eaglercraft.EarlyLoadScreen; +import net.lax1dude.eaglercraft.ExpiringSet; +import net.lax1dude.eaglercraft.LocalStorageManager; +import net.lax1dude.eaglercraft.ServerQuery; +import net.lax1dude.eaglercraft.Voice; import net.lax1dude.eaglercraft.adapter.teavm.EaglercraftVoiceClient; import net.lax1dude.eaglercraft.adapter.teavm.SelfDefence; import net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext; -import static net.lax1dude.eaglercraft.adapter.teavm.WebGL2RenderingContext.*; +import net.lax1dude.eaglercraft.adapter.teavm.WebGLQuery; +import net.lax1dude.eaglercraft.adapter.teavm.WebGLVertexArray; +import net.minecraft.src.MathHelper; public class EaglerAdapterImpl2 {