1
0
mirror of https://e.coding.net/circlecloud/YumCore.git synced 2024-11-18 01:09:03 +00:00

删除废物代码

This commit is contained in:
xjboss 2019-03-12 11:22:49 +00:00
parent 15ef089371
commit 6583a6a8d9

View File

@ -69,13 +69,6 @@ public class C {
chatSerializer = nmsChatSerializer.getMethod("func_150699_a", String.class); chatSerializer = nmsChatSerializer.getMethod("func_150699_a", String.class);
nmsIChatBaseComponent = Class.forName("net.minecraft.util.IChatComponent"); nmsIChatBaseComponent = Class.forName("net.minecraft.util.IChatComponent");
packetType = Class.forName("net.minecraft.network.play.server.S02PacketChat"); packetType = Class.forName("net.minecraft.network.play.server.S02PacketChat");
Arrays.stream(packetType.getConstructors()).forEach(c -> {
if (c.getParameterTypes().length == 2&&uranium) {
packetTypeConstructor = c;
}else if(c.getParameterTypes().length==1){
packetTypeConstructor = c;
}
});
}else { }else {
newversion = Integer.parseInt(version.split("_")[1]) > 7; newversion = Integer.parseInt(version.split("_")[1]) > 7;
titlePAB=newversion; titlePAB=newversion;
@ -83,12 +76,12 @@ public class C {
chatSerializer = nmsChatSerializer.getMethod("a", String.class); chatSerializer = nmsChatSerializer.getMethod("a", String.class);
nmsIChatBaseComponent = Class.forName(a("IChatBaseComponent")); nmsIChatBaseComponent = Class.forName(a("IChatBaseComponent"));
packetType = Class.forName(a("PacketPlayOutChat")); packetType = Class.forName(a("PacketPlayOutChat"));
}
Arrays.stream(packetType.getConstructors()).forEach(c -> { Arrays.stream(packetType.getConstructors()).forEach(c -> {
if (c.getParameterTypes().length == 2) { if (c.getParameterTypes().length == 2) {
packetTypeConstructor = c; packetTypeConstructor = c;
} }
}); });
}
try { try {
nmsChatMessageTypeClass = packetTypeConstructor.getParameterTypes()[1]; nmsChatMessageTypeClass = packetTypeConstructor.getParameterTypes()[1];
if (nmsChatMessageTypeClass.isEnum()) { if (nmsChatMessageTypeClass.isEnum()) {