mirror of
https://github.com/TotalFreedomMC/TF-LibsDisguises.git
synced 2025-02-11 19:50:30 +00:00
If the observer is riding the disguised entity, don't do weird player stuff
This commit is contained in:
parent
a45f7a8076
commit
7ab4a31c1f
1 changed files with 1 additions and 1 deletions
|
@ -206,7 +206,7 @@ public class PacketHandlerSpawn implements IPacketHandler {
|
|||
double dist = observer.getLocation().distanceSquared(disguisedEntity.getLocation());
|
||||
|
||||
// If self disguise, or further than 50 blocks, or not in front of entity
|
||||
normalPlayerDisguise = observer == disguisedEntity || dist > (50 * 50) ||
|
||||
normalPlayerDisguise = observer == disguisedEntity || disguisedEntity.getPassengers().contains(observer) || dist > (50 * 50) ||
|
||||
(observer.getLocation().add(observer.getLocation().getDirection().normalize()).distanceSquared(disguisedEntity.getLocation()) - dist) < 0.3;
|
||||
sendArmor = normalPlayerDisguise;
|
||||
|
||||
|
|
Loading…
Reference in a new issue