9
0
mirror of https://github.com/LeavesMC/Leaves.git synced 2025-12-28 11:29:12 +00:00
Files
LeavesMC/patches/server/0125-Configurable-MC-67.patch
2024-08-14 17:07:19 +08:00

20 lines
1.2 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Lumine1909 <133463833+Lumine1909@users.noreply.github.com>
Date: Wed, 26 Jun 2024 18:15:57 +0800
Subject: [PATCH] Configurable MC-67
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 99ad282dcc026b45cbe5b4af22db3da02e837d10..b5f35946cf60cc37eaa0d9242579dc74c3f3b93a 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -3914,7 +3914,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
}
public boolean canChangeDimensions(Level from, Level to) {
- return this.isAlive() && this.valid; // Paper - Fix item duplication and teleport issues
+ return !(!org.leavesmc.leaves.LeavesConfig.allowEntityPortalWithPassenger && (this.isPassenger() || this.isVehicle())) && this.isAlive() && this.valid; // Paper - Fix item duplication and teleport issues // Leaves - allowEntityPortalWithPassenger
}
public float getBlockExplosionResistance(Explosion explosion, BlockGetter world, BlockPos pos, BlockState blockState, FluidState fluidState, float max) {