Don't bother checking if the entity is disguised before cancelling packet as it should be cancelled anyways
This commit is contained in:
parent
4aa148d1eb
commit
25a6e713af
@ -111,8 +111,7 @@ public class PacketsManager {
|
||||
Player observer = event.getPlayer();
|
||||
StructureModifier<Entity> entityModifer = event.getPacket().getEntityModifier(observer.getWorld());
|
||||
org.bukkit.entity.Entity entity = entityModifer.read(1);
|
||||
if (DisguiseAPI.isDisguised(entity)
|
||||
&& (entity instanceof ExperienceOrb || entity instanceof Item || entity instanceof Arrow)) {
|
||||
if (entity instanceof ExperienceOrb || entity instanceof Item || entity instanceof Arrow) {
|
||||
event.setCancelled(true);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
|
Loading…
Reference in New Issue
Block a user