Send rel look for 1.15 head rotation packet
This commit is contained in:
		| @@ -24,7 +24,10 @@ public class PacketHandlerHeadRotation implements IPacketHandler { | |||||||
|     @Override |     @Override | ||||||
|     public void handle(Disguise disguise, PacketContainer sentPacket, LibsPackets packets, Player observer, |     public void handle(Disguise disguise, PacketContainer sentPacket, LibsPackets packets, Player observer, | ||||||
|             Entity entity) { |             Entity entity) { | ||||||
|         if (disguise.getType().isPlayer() && entity.getType() != EntityType.PLAYER) { |         if (!disguise.getType().isPlayer() || entity.getType() == EntityType.PLAYER) { | ||||||
|  |             return; | ||||||
|  |         } | ||||||
|  |  | ||||||
|         Location loc = entity.getLocation(); |         Location loc = entity.getLocation(); | ||||||
|  |  | ||||||
|         byte pitch = DisguiseUtilities |         byte pitch = DisguiseUtilities | ||||||
| @@ -38,7 +41,7 @@ public class PacketHandlerHeadRotation implements IPacketHandler { | |||||||
|         mods.write(0, entity.getEntityId()); |         mods.write(0, entity.getEntityId()); | ||||||
|         mods.write(1, yaw); |         mods.write(1, yaw); | ||||||
|  |  | ||||||
|             PacketContainer look = new PacketContainer(PacketType.Play.Server.ENTITY_LOOK); |         PacketContainer look = new PacketContainer(PacketType.Play.Server.REL_ENTITY_MOVE_LOOK); | ||||||
|  |  | ||||||
|         look.getIntegers().write(0, entity.getEntityId()); |         look.getIntegers().write(0, entity.getEntityId()); | ||||||
|         look.getBytes().write(0, yaw); |         look.getBytes().write(0, yaw); | ||||||
| @@ -50,4 +53,3 @@ public class PacketHandlerHeadRotation implements IPacketHandler { | |||||||
|         packets.addPacket(rotation); |         packets.addPacket(rotation); | ||||||
|     } |     } | ||||||
| } | } | ||||||
| } |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user