Fix error
This commit is contained in:
parent
b29e8e6115
commit
af51c6def0
@ -110,7 +110,7 @@ public class PacketsManager {
|
|||||||
try {
|
try {
|
||||||
Player observer = event.getPlayer();
|
Player observer = event.getPlayer();
|
||||||
StructureModifier<Entity> entityModifer = event.getPacket().getEntityModifier(observer.getWorld());
|
StructureModifier<Entity> entityModifer = event.getPacket().getEntityModifier(observer.getWorld());
|
||||||
org.bukkit.entity.Entity entity = entityModifer.read(ReflectionManager.isAfter17() ? 1 : 0);
|
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) {
|
||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user