From fb441b4910ab2fde84cf4f2938afb9e2ad976d86 Mon Sep 17 00:00:00 2001 From: "Kristian S. Stangeland" Date: Tue, 2 Apr 2013 14:12:36 +0200 Subject: [PATCH] Retrieve the correct Minecraft superclass --- .../protocol/injector/player/NetworkServerInjector.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ProtocolLib/src/main/java/com/comphenix/protocol/injector/player/NetworkServerInjector.java b/ProtocolLib/src/main/java/com/comphenix/protocol/injector/player/NetworkServerInjector.java index 207bcba3..610d1a8b 100644 --- a/ProtocolLib/src/main/java/com/comphenix/protocol/injector/player/NetworkServerInjector.java +++ b/ProtocolLib/src/main/java/com/comphenix/protocol/injector/player/NetworkServerInjector.java @@ -249,7 +249,7 @@ class NetworkServerInjector extends PlayerInjector { } private Class getFirstMinecraftSuperClass(Class clazz) { - if (clazz.getName().startsWith(MinecraftReflection.getMinecraftPackage())) + if (MinecraftReflection.isMinecraftClass(clazz)) return clazz; else if (clazz.equals(Object.class)) return clazz;