Some testing code I'd like to keep.
This commit is contained in:
parent
eb01c0ff46
commit
4ae99ba9d5
|
@ -31,12 +31,6 @@
|
|||
<version>1.15.2-R0.1-SNAPSHOT</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.spigotmc</groupId>
|
||||
<artifactId>spigot</artifactId>
|
||||
<version>1.15.2-R0.1-SNAPSHOT</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.mojang</groupId>
|
||||
<artifactId>authlib</artifactId>
|
||||
|
|
|
@ -291,6 +291,11 @@ public abstract class TinyProtocol {
|
|||
}
|
||||
}
|
||||
|
||||
// Keeping this here for testing purposes:
|
||||
// public Object onPacketOutAsync(Player receiver, Channel channel, Object packet) {
|
||||
// return packet;
|
||||
// }
|
||||
|
||||
private final class PacketInterceptor extends ChannelDuplexHandler {
|
||||
// Updated by the login event
|
||||
public volatile Player player;
|
||||
|
@ -312,6 +317,20 @@ public abstract class TinyProtocol {
|
|||
}
|
||||
}
|
||||
|
||||
// Keeping this here for testing purposes:
|
||||
// @Override
|
||||
// public void write(ChannelHandlerContext ctx, Object msg, ChannelPromise promise) throws Exception {
|
||||
// try {
|
||||
// msg = onPacketOutAsync(player, ctx.channel(), msg);
|
||||
// } catch (Exception e) {
|
||||
// instance.getLogger().severe("Error in onPacketOutAsync().", e);
|
||||
// }
|
||||
//
|
||||
// if (msg != null) {
|
||||
// super.write(ctx, msg, promise);
|
||||
// }
|
||||
// }
|
||||
|
||||
private void handleLoginStart(Channel channel, Object packet) {
|
||||
if (PACKET_LOGIN_IN_START.isInstance(packet)) {
|
||||
GameProfile profile = getGameProfile.get(packet);
|
||||
|
|
Loading…
Reference in New Issue