Upstream has released updates that appears to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing Developers!: You will need to clean up your work/Minecraft/1.13.2 folder for this Also, restore a patch that was dropped in the last upstream Bukkit Changes: 279eeab3 Fix command description not being set 96e2bb18 Remove debug print from SyntheticEventTest CraftBukkit Changes: d3ed1516 Fix dangerously threaded beacons 217a293d Don't relocate joptsimple to allow --help to work. 1be05a21 Prepare for imminent Java 12 release a49270b2 Mappings Update 5259d80c SPIGOT-4669: Fix PlayerTeleportEvent coordinates for relative teleports Spigot Changes: e6eb36f2 Rebuild patches
37 lines
1.5 KiB
Diff
37 lines
1.5 KiB
Diff
From 4d741d79e00149f2ade3d413f34ddb333131b54b Mon Sep 17 00:00:00 2001
|
|
From: Aikar <aikar@aikar.co>
|
|
Date: Sat, 16 Jun 2018 16:23:38 -0400
|
|
Subject: [PATCH] Ignore Missing Recipes in RecipeBook to avoid data errors
|
|
|
|
This code was causing NPE's in saving player data, potentially related to reloads.
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/RecipeBookServer.java b/src/main/java/net/minecraft/server/RecipeBookServer.java
|
|
index 5a21aed43..4d9f3d369 100644
|
|
--- a/src/main/java/net/minecraft/server/RecipeBookServer.java
|
|
+++ b/src/main/java/net/minecraft/server/RecipeBookServer.java
|
|
@@ -78,6 +78,10 @@ public class RecipeBookServer extends RecipeBook {
|
|
while (iterator.hasNext()) {
|
|
MinecraftKey minecraftkey = (MinecraftKey) iterator.next();
|
|
|
|
+ // Paper start - ignore missing recipes
|
|
+ IRecipe recipe = this.h.a(minecraftkey);
|
|
+ if (recipe == null) continue;
|
|
+ // Paper end
|
|
nbttaglist.add((NBTBase) (new NBTTagString(minecraftkey.toString())));
|
|
}
|
|
|
|
@@ -88,6 +92,10 @@ public class RecipeBookServer extends RecipeBook {
|
|
while (iterator1.hasNext()) {
|
|
MinecraftKey minecraftkey1 = (MinecraftKey) iterator1.next();
|
|
|
|
+ // Paper start - ignore missing recipes
|
|
+ IRecipe recipe = this.h.a(minecraftkey1);
|
|
+ if (recipe == null) continue;
|
|
+ // Paper end
|
|
nbttaglist1.add((NBTBase) (new NBTTagString(minecraftkey1.toString())));
|
|
}
|
|
|
|
--
|
|
2.21.0
|
|
|