aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/server/0578-Add-back-EntityPortalExitEvent.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patches/server/0578-Add-back-EntityPortalExitEvent.patch')
-rw-r--r--patches/server/0578-Add-back-EntityPortalExitEvent.patch8
1 files changed, 3 insertions, 5 deletions
diff --git a/patches/server/0578-Add-back-EntityPortalExitEvent.patch b/patches/server/0578-Add-back-EntityPortalExitEvent.patch
index a082311306..5e3f9b5ffd 100644
--- a/patches/server/0578-Add-back-EntityPortalExitEvent.patch
+++ b/patches/server/0578-Add-back-EntityPortalExitEvent.patch
@@ -5,19 +5,17 @@ Subject: [PATCH] Add back EntityPortalExitEvent
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
-index fe9cdd104d6203233a90068b55e0876be4964afe..96d73407edd440c16d41c8a586797ade30792f46 100644
+index fe9cdd104d6203233a90068b55e0876be4964afe..88d3b1997bba632c5746d295bb39095f5d328369 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
-@@ -3491,7 +3491,8 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
+@@ -3491,6 +3491,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
if (!this.isRemoved()) {
// CraftBukkit start
PositionMoveRotation absolutePosition = PositionMoveRotation.calculateAbsolute(PositionMoveRotation.of(this), PositionMoveRotation.of(teleportTarget), teleportTarget.relatives());
-- Location to = CraftLocation.toBukkit(absolutePosition.position(), teleportTarget.newLevel().getWorld(), absolutePosition.yRot(), absolutePosition.xRot());
+ Vec3 velocity = absolutePosition.deltaMovement(); // Paper
-+ Location to = CraftLocation.toBukkit(absolutePosition.position(), teleportTarget.newLevel().getWorld(), absolutePosition.yRot(), this.getXRot()); // Paper - use getXRot (doesn't respect DimensionTransition pitch) // Why?
+ Location to = CraftLocation.toBukkit(absolutePosition.position(), teleportTarget.newLevel().getWorld(), absolutePosition.yRot(), absolutePosition.xRot());
// Paper start - gateway-specific teleport event
final EntityTeleportEvent teleEvent;
- if (this.portalProcess != null && this.portalProcess.isSamePortal(((net.minecraft.world.level.block.EndGatewayBlock) net.minecraft.world.level.block.Blocks.END_GATEWAY)) && this.level.getBlockEntity(this.portalProcess.getEntryPosition()) instanceof net.minecraft.world.level.block.entity.TheEndGatewayBlockEntity theEndGatewayBlockEntity) {
@@ -3507,7 +3508,29 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
if (!to.equals(teleEvent.getTo())) {
to = teleEvent.getTo();