Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3176184
commit 6657b9c
Showing
2 changed files
with
19 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 | ||
From: kugge <sofiane.djerbi38@gmail.com> | ||
Date: Thu, 22 Jun 2023 20:32:58 +0200 | ||
Subject: [PATCH] Fix teleportAsync rotation API | ||
|
||
|
||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java | ||
index 76bcfda336e9cfa039d80ea3ccbebbc3d2b13f7f..24617b3994c0f148f1c17928e18aa1e1a784e6f5 100644 | ||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java | ||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java | ||
@@ -1329,7 +1329,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { | ||
boolean success = nmsEntity.teleportAsync( | ||
((CraftWorld)locationClone.getWorld()).getHandle(), | ||
new net.minecraft.world.phys.Vec3(locationClone.getX(), locationClone.getY(), locationClone.getZ()), | ||
- null, null, net.minecraft.world.phys.Vec3.ZERO, | ||
+ locationClone.getYaw(), locationClone.getPitch(), net.minecraft.world.phys.Vec3.ZERO, // Kaiiju - fix teleportAsync() rotation | ||
cause == null ? TeleportCause.UNKNOWN : cause, | ||
Entity.TELEPORT_FLAG_LOAD_CHUNK | Entity.TELEPORT_FLAG_UNMOUNT, // preserve behavior with old API: dismount the entity so it can teleport | ||
(Entity entityTp) -> { |
This file was deleted.
Oops, something went wrong.