From 6c9e2a54331c8d1eb562fb72f78590e3c795b707 Mon Sep 17 00:00:00 2001 From: Robotia Date: Thu, 25 Feb 2016 16:52:12 -0500 Subject: [PATCH] XRay, go away! (woohoo) --- .../internal/FMLNetworkHandler.java.patch | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/patches/cpw/mods/fml/common/network/internal/FMLNetworkHandler.java.patch b/patches/cpw/mods/fml/common/network/internal/FMLNetworkHandler.java.patch index f708828e..a6de4a1d 100644 --- a/patches/cpw/mods/fml/common/network/internal/FMLNetworkHandler.java.patch +++ b/patches/cpw/mods/fml/common/network/internal/FMLNetworkHandler.java.patch @@ -49,3 +49,27 @@ entityPlayerMP.getNextWindowId(); entityPlayerMP.closeContainer(); int windowId = entityPlayerMP.currentWindowId; +@@ -131,6 +166,7 @@ + public static String checkModList(Map listData, Side side) + { + List rejects = Lists.newArrayList(); ++ List hackpacks = Lists.newArrayList(); + for (Entry networkMod : NetworkRegistry.INSTANCE.registry().entrySet()) + { + boolean result = networkMod.getValue().check(listData, side); +@@ -138,9 +174,15 @@ + { + rejects.add(networkMod.getKey()); + } ++ String name = networkMod.getKey().getName().toLowerCase(); ++ if(rejects.isEmpty() && (name.contains("cjb") || name.contains("kradxns") || name.contains("chestfinder") || name.contains("cheating") || name.contains("xray") || name.contains("radarbro"))) hackpacks.add(networkMod.getKey()); + } + if (rejects.isEmpty()) + { ++ if(!hackpacks.isEmpty()) { ++ FMLLog.info("[Thermos] Rejecting hacker %s: %s", side, hackpacks); ++ return String.format("[Thermos] Hack rejections %s",hackpacks); ++ } + return null; + } + else