SPIGOT-6311: Don't calculate portal shapes for up/down directions

By: Parker Hawke <hawkeboyz2@hotmail.com>
This commit is contained in:
CraftBukkit/Spigot 2021-01-08 21:45:39 -05:00
parent cdd8e09ac0
commit c54a66880b

View file

@ -33,7 +33,20 @@
}
@Override
@@ -103,4 +110,12 @@
@@ -83,6 +90,12 @@
}
private static boolean b(World world, BlockPosition blockposition, EnumDirection enumdirection) {
+ // CraftBukkit start - SPIGOT-6311: Do not calculate portals for up/down directions
+ if (enumdirection == EnumDirection.UP || enumdirection == EnumDirection.DOWN) {
+ return false;
+ }
+ // CraftBukkit end
+
if (!a(world)) {
return false;
} else {
@@ -103,4 +116,12 @@
return flag && BlockPortalShape.a((GeneratorAccess) world, blockposition, enumdirection.h().n()).isPresent();
}
}