diff --git a/src/me/libraryaddict/disguise/utilities/PacketsManager.java b/src/me/libraryaddict/disguise/utilities/PacketsManager.java index ad7e71da..c865609d 100644 --- a/src/me/libraryaddict/disguise/utilities/PacketsManager.java +++ b/src/me/libraryaddict/disguise/utilities/PacketsManager.java @@ -116,7 +116,8 @@ public class PacketsManager { Player observer = event.getPlayer(); StructureModifier entityModifer = event.getPacket().getEntityModifier(observer.getWorld()); org.bukkit.entity.Entity entity = entityModifer.read(ReflectionManager.isAfter17() ? 0 : 1); - if (entity instanceof ExperienceOrb || entity instanceof Item || entity instanceof Arrow) { + if (entity instanceof ExperienceOrb || entity instanceof Item || entity instanceof Arrow + || entity == observer) { event.setCancelled(true); } } catch (Exception e) { diff --git a/src/me/libraryaddict/disguise/utilities/ReflectionManager.java b/src/me/libraryaddict/disguise/utilities/ReflectionManager.java index c19bd2f9..a7cd24dc 100644 --- a/src/me/libraryaddict/disguise/utilities/ReflectionManager.java +++ b/src/me/libraryaddict/disguise/utilities/ReflectionManager.java @@ -258,16 +258,13 @@ public class ReflectionManager { stage++; switch (stage) { case 1: - x = field.getDouble(boundingBox); //+ oldBox.getX(); - // field.setDouble(boundingBox, x - newBox.getX()); + x = field.getDouble(boundingBox); break; case 2: - y = field.getDouble(boundingBox);// + oldBox.getY(); - // field.setDouble(boundingBox, y - newBox.getY()); + y = field.getDouble(boundingBox); break; case 3: - z = field.getDouble(boundingBox); //+ oldBox.getZ(); - // field.setDouble(boundingBox, z - newBox.getZ()); + z = field.getDouble(boundingBox); break; case 4: field.setDouble(boundingBox, x + newBox.getX());