From 0bc1b7ecaf6c53448a499160f0059b6af3140099 Mon Sep 17 00:00:00 2001 From: Dan Mulloy Date: Fri, 5 Dec 2014 21:45:45 -0500 Subject: [PATCH] Correct casing of Vec3D --- .../java/com/comphenix/protocol/events/PacketContainer.java | 2 +- .../com/comphenix/protocol/utility/MinecraftReflection.java | 4 ++-- .../com/comphenix/protocol/wrappers/BukkitConverters.java | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ProtocolLib/src/main/java/com/comphenix/protocol/events/PacketContainer.java b/ProtocolLib/src/main/java/com/comphenix/protocol/events/PacketContainer.java index c6965edb..c2d88b5f 100644 --- a/ProtocolLib/src/main/java/com/comphenix/protocol/events/PacketContainer.java +++ b/ProtocolLib/src/main/java/com/comphenix/protocol/events/PacketContainer.java @@ -507,7 +507,7 @@ public class PacketContainer implements Serializable { public StructureModifier getVectors() { // Automatically marshal between Vec3d and the Bukkit wrapper return structureModifier.withType( - MinecraftReflection.getVec3dClass(), + MinecraftReflection.getVec3DClass(), BukkitConverters.getVectorConverter()); } diff --git a/ProtocolLib/src/main/java/com/comphenix/protocol/utility/MinecraftReflection.java b/ProtocolLib/src/main/java/com/comphenix/protocol/utility/MinecraftReflection.java index 22c07c6b..b226a646 100644 --- a/ProtocolLib/src/main/java/com/comphenix/protocol/utility/MinecraftReflection.java +++ b/ProtocolLib/src/main/java/com/comphenix/protocol/utility/MinecraftReflection.java @@ -1241,9 +1241,9 @@ public class MinecraftReflection { * Retrieves the Vec3d class. * @return The Vec3d class. */ - public static Class getVec3dClass() { + public static Class getVec3DClass() { try { - return getMinecraftClass("Vec3d"); + return getMinecraftClass("Vec3D"); } catch (RuntimeException e) { // TODO: Figure out a fuzzy field contract return null; diff --git a/ProtocolLib/src/main/java/com/comphenix/protocol/wrappers/BukkitConverters.java b/ProtocolLib/src/main/java/com/comphenix/protocol/wrappers/BukkitConverters.java index c08ba9ca..5dd1070d 100644 --- a/ProtocolLib/src/main/java/com/comphenix/protocol/wrappers/BukkitConverters.java +++ b/ProtocolLib/src/main/java/com/comphenix/protocol/wrappers/BukkitConverters.java @@ -821,7 +821,7 @@ public class BukkitConverters { protected Object getGenericValue(Class genericType, Vector specific) { if (vec3dConstructor == null) { try { - vec3dConstructor = MinecraftReflection.getVec3dClass().getConstructor( + vec3dConstructor = MinecraftReflection.getVec3DClass().getConstructor( double.class, double.class, double.class); } catch (Throwable ex) { throw new RuntimeException("Could not find Vec3d constructor (double, double, double)"); @@ -838,7 +838,7 @@ public class BukkitConverters { @Override protected Vector getSpecificValue(Object generic) { if (vec3dModifier == null) { - vec3dModifier = new StructureModifier(MinecraftReflection.getVec3dClass(), false); + vec3dModifier = new StructureModifier(MinecraftReflection.getVec3DClass(), false); } StructureModifier doubles = vec3dModifier.withTarget(generic).withType(double.class);