mirror of
https://github.com/libraryaddict/LibsDisguises.git
synced 2024-11-05 09:09:40 +01:00
Fixed experience orb self disguise
This commit is contained in:
parent
789740c358
commit
f3ef6e13f3
@ -270,8 +270,17 @@ public abstract class Disguise {
|
||||
packet.getIntegers().write(0, getEntity().getEntityId());
|
||||
try {
|
||||
for (Player player : DisguiseUtilities.getPerverts(disguise)) {
|
||||
if (DisguiseConfig.isViewDisguises() || getEntity() != player) {
|
||||
if (getEntity() != player) {
|
||||
ProtocolLibrary.getProtocolManager().sendServerPacket(player, packet, false);
|
||||
} else if (isSelfDisguiseVisible()) {
|
||||
PacketContainer selfPacket = packet.shallowClone();
|
||||
selfPacket.getModifier().write(0, DisguiseAPI.getFakeDisguise(getEntity().getEntityId()));
|
||||
try {
|
||||
ProtocolLibrary.getProtocolManager().sendServerPacket((Player) getEntity(),
|
||||
selfPacket, false);
|
||||
} catch (InvocationTargetException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (InvocationTargetException e) {
|
||||
|
Loading…
Reference in New Issue
Block a user