Clean up Apache Mina, goodbye!

This commit is contained in:
P0nk
2021-07-13 22:10:01 +02:00
parent 94e1125eca
commit 81393392ab
9 changed files with 5 additions and 289 deletions

View File

@@ -45,7 +45,6 @@ import net.server.coordinator.session.MapleSessionCoordinator.AntiMulticlientRes
import net.server.guild.MapleGuild;
import net.server.guild.MapleGuildCharacter;
import net.server.world.*;
import org.apache.mina.core.session.IoSession;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import scripting.AbstractPlayerInteraction;
@@ -86,10 +85,6 @@ public class MapleClient extends ChannelInboundHandlerAdapter {
public static final int LOGIN_NOTLOGGEDIN = 0;
public static final int LOGIN_SERVER_TRANSITION = 1;
public static final int LOGIN_LOGGEDIN = 2;
public static final String CLIENT_KEY = "CLIENT";
public static final String CLIENT_HWID = "HWID";
public static final String CLIENT_NIBBLEHWID = "HWID2";
public static final String CLIENT_REMOTE_ADDRESS = "REMOTE_IP";
private final Type type;
@@ -98,9 +93,6 @@ public class MapleClient extends ChannelInboundHandlerAdapter {
private String remoteAddress;
private volatile boolean inTransition;
private MapleAESOFB send;
private MapleAESOFB receive;
private io.netty.channel.Channel ioChannel;
private PacketProcessor packetProcessor;
private MapleCharacter player;
@@ -158,12 +150,6 @@ public class MapleClient extends ChannelInboundHandlerAdapter {
this.channel = channel;
}
public MapleClient(MapleAESOFB send, MapleAESOFB receive, IoSession session) {
this.type = null;
this.send = send;
this.receive = receive;
}
public static MapleClient createMock() {
return new MapleClient(null, null, -123, -123);
}
@@ -275,14 +261,6 @@ public class MapleClient extends ChannelInboundHandlerAdapter {
ioChannel.disconnect();
}
public MapleAESOFB getReceiveCrypto() {
return receive;
}
public MapleAESOFB getSendCrypto() {
return send;
}
public Hwid getHwid() {
return hwid;
}
@@ -1097,9 +1075,6 @@ public class MapleClient extends ChannelInboundHandlerAdapter {
this.birthday = null;
this.engines = null;
this.player = null;
this.receive = null;
this.send = null;
//this.session = null;
}
public void setCharacterOnSessionTransitionState(int cid) {
@@ -1171,11 +1146,6 @@ public class MapleClient extends ChannelInboundHandlerAdapter {
lastPong = System.currentTimeMillis();
}
@Deprecated(forRemoval = true)
public void testPing(long timeThen) {
throw new UnsupportedOperationException();
}
public void checkIfIdle(final IdleStateEvent event) {
final long pingedAt = System.currentTimeMillis();
announce(MaplePacketCreator.getPing());