mirror of
https://github.com/PaperMC/Paper.git
synced 2026-11-25 02:19:41 -05:00
SPIGOT-619: Force rotate head of entities when setting location.
This commit is contained in:
1 parent
281376dfb5
commit
5245147d00
1 file changed
+4
-1
@@ -257,8 +257,11 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
|
||||
entity.stopRiding();
|
||||
|
||||
entity.world = ((CraftWorld) location.getWorld()).getHandle();
|
||||
entity.setLocation(location.getX(), location.getY(), location.getZ(), location.getYaw(), location.getPitch());
|
||||
// entity.setLocation() throws no event, and so cannot be cancelled
|
||||
entity.setLocation(location.getX(), location.getY(), location.getZ(), location.getYaw(), location.getPitch());
|
||||
// SPIGOT-619: Force sync head rotation also
|
||||
entity.h(location.getYaw()); // PAIL: setHeadRotation
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user