mirror of
https://github.com/TotalFreedomMC/TF-LibsDisguises.git
synced 2025-02-14 12:50:13 +00:00
Fixed experience orb self disguise
This commit is contained in:
parent
789740c358
commit
f3ef6e13f3
1 changed files with 10 additions and 1 deletions
|
@ -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 a new issue