Paper/nms-patches/DefinedStructure.patch
2019-04-23 12:00:00 +10:00

39 lines
1.5 KiB
Diff

--- a/net/minecraft/server/DefinedStructure.java
+++ b/net/minecraft/server/DefinedStructure.java
@@ -84,7 +84,7 @@
}
private void a(World world, BlockPosition blockposition, BlockPosition blockposition1) {
- List<Entity> list = world.a(Entity.class, new AxisAlignedBB(blockposition, blockposition1), (entity) -> {
+ List<Entity> list = world.a(Entity.class, new AxisAlignedBB(blockposition, blockposition1), (java.util.function.Predicate) (entity) -> { // CraftBukkit - decompile error
return !(entity instanceof EntityHuman);
});
@@ -384,11 +384,13 @@
}
private static Optional<Entity> a(GeneratorAccess generatoraccess, NBTTagCompound nbttagcompound) {
- try {
+ // CraftBukkit start
+ // try {
return EntityTypes.a(nbttagcompound, generatoraccess.getMinecraftWorld());
- } catch (Exception exception) {
- return Optional.empty();
- }
+ // } catch (Exception exception) {
+ // return Optional.empty();
+ // }
+ // CraftBukkit end
}
public BlockPosition a(EnumBlockRotation enumblockrotation) {
@@ -797,7 +799,7 @@
public IBlockData a(int i) {
IBlockData iblockdata = (IBlockData) this.b.fromId(i);
- return iblockdata == null ? DefinedStructure.a.a : iblockdata;
+ return iblockdata == null ? a : iblockdata; // CraftBukkit - decompile error
}
public Iterator<IBlockData> iterator() {