Stop the disguised recieving packets

This commit is contained in:
Andrew 2013-07-12 08:33:17 +12:00
parent 214aaa2fd9
commit 84919eeea5

View file

@ -96,6 +96,8 @@ public class LibsDisguises extends JavaPlugin implements Listener {
Player observer = event.getPlayer();
StructureModifier<Entity> entityModifer = event.getPacket().getEntityModifier(observer.getWorld());
org.bukkit.entity.Entity entity = entityModifer.read((Packets.Server.COLLECT == event.getPacketID() ? 1 : 0));
if (entity == observer)
return;
if (DisguiseAPI.isDisguised(entity)) {
Disguise disguise = DisguiseAPI.getDisguise(entity);
if (event.getPacketID() == 44) {