aboutsummaryrefslogtreecommitdiffhomepage
path: root/patch-remap/og/net/minecraft/util/datafix/fixes
diff options
context:
space:
mode:
Diffstat (limited to 'patch-remap/og/net/minecraft/util/datafix/fixes')
-rw-r--r--patch-remap/og/net/minecraft/util/datafix/fixes/DataConverterFlatten.patch11
-rw-r--r--patch-remap/og/net/minecraft/util/datafix/fixes/DataConverterMap.patch11
2 files changed, 22 insertions, 0 deletions
diff --git a/patch-remap/og/net/minecraft/util/datafix/fixes/DataConverterFlatten.patch b/patch-remap/og/net/minecraft/util/datafix/fixes/DataConverterFlatten.patch
new file mode 100644
index 0000000000..6916dff542
--- /dev/null
+++ b/patch-remap/og/net/minecraft/util/datafix/fixes/DataConverterFlatten.patch
@@ -0,0 +1,11 @@
+--- a/net/minecraft/util/datafix/fixes/DataConverterFlatten.java
++++ b/net/minecraft/util/datafix/fixes/DataConverterFlatten.java
+@@ -376,7 +376,7 @@
+ Typed<?> typed2 = typed.getOrCreateTyped(opticfinder1);
+ Dynamic<?> dynamic1 = (Dynamic) typed2.get(DSL.remainderFinder());
+
+- dynamic1 = dynamic1.set("Damage", dynamic1.createInt(i));
++ if (i != 0) dynamic1 = dynamic1.set("Damage", dynamic1.createInt(i)); // CraftBukkit
+ typed1 = typed1.set(opticfinder1, typed2.set(DSL.remainderFinder(), dynamic1));
+ }
+
diff --git a/patch-remap/og/net/minecraft/util/datafix/fixes/DataConverterMap.patch b/patch-remap/og/net/minecraft/util/datafix/fixes/DataConverterMap.patch
new file mode 100644
index 0000000000..41b8ab111a
--- /dev/null
+++ b/patch-remap/og/net/minecraft/util/datafix/fixes/DataConverterMap.patch
@@ -0,0 +1,11 @@
+--- a/net/minecraft/util/datafix/fixes/DataConverterMap.java
++++ b/net/minecraft/util/datafix/fixes/DataConverterMap.java
+@@ -32,7 +32,7 @@
+ Typed<?> typed1 = typed.getOrCreateTyped(opticfinder1);
+ Dynamic<?> dynamic1 = (Dynamic) typed1.get(DSL.remainderFinder());
+
+- dynamic1 = dynamic1.set("map", dynamic1.createInt(dynamic.get("Damage").asInt(0)));
++ if (!dynamic1.getElement("map").result().isPresent()) dynamic1 = dynamic1.set("map", dynamic1.createInt(dynamic.get("Damage").asInt(0))); // CraftBukkit
+ return typed.set(opticfinder1, typed1.set(DSL.remainderFinder(), dynamic1));
+ } else {
+ return typed;