Skip to content

Commit

Permalink
fix patches for 24w10a, closes #27
Browse files Browse the repository at this point in the history
  • Loading branch information
MiniDigger committed Apr 23, 2024
1 parent 5ecee0b commit 335bc3f
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 8 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/net/minecraft/commands/synchronization/ArgumentTypeInfos.java
+++ b/net/minecraft/commands/synchronization/ArgumentTypeInfos.java
@@ -116,10 +_,10 @@
@@ -118,10 +_,10 @@
register(registry, "dimension", DimensionArgument.class, SingletonArgumentInfo.contextFree(DimensionArgument::dimension));
register(registry, "gamemode", GameModeArgument.class, SingletonArgumentInfo.contextFree(GameModeArgument::gameMode));
register(registry, "time", TimeArgument.class, new TimeArgument.Info());
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/net/minecraft/core/registries/BuiltInRegistries.java
+++ b/net/minecraft/core/registries/BuiltInRegistries.java
@@ -288,7 +_,7 @@
@@ -285,7 +_,7 @@
Bootstrap.checkBootstrapCalled(() -> "registry " + resourceKey);
ResourceLocation resourceLocation = resourceKey.location();
LOADERS.put(resourceLocation, () -> registryBootstrap.run(writableRegistry));
Expand Down
4 changes: 2 additions & 2 deletions versions/24w10a/patches/net/minecraft/nbt/NbtUtils.java.patch
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/net/minecraft/nbt/NbtUtils.java
+++ b/net/minecraft/nbt/NbtUtils.java
@@ -379,7 +_,7 @@
@@ -310,7 +_,7 @@
indent(indentLevel + 1, stringBuilder);
}

Expand All @@ -9,7 +9,7 @@
String stringx = Strings.repeat(" ", ix);

for (int i2 = 0; i2 < list.size(); i2++) {
@@ -406,7 +_,7 @@
@@ -337,7 +_,7 @@
case 11:
IntArrayTag intArrayTag = (IntArrayTag)tag;
int[] asIntArray = intArrayTag.getAsIntArray();
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
--- a/net/minecraft/resources/HolderSetCodec.java
+++ b/net/minecraft/resources/HolderSetCodec.java
@@ -70,7 +_,7 @@

private static <E> DataResult<HolderSet<E>> lookupTag(HolderGetter<E> holderGetter, TagKey<E> tagKey) {
return holderGetter.get(tagKey)
- .map(DataResult::success)
+ .map(DataResult::<HolderSet<E>>success)
.orElseGet(() -> DataResult.error(() -> "Missing tag: '" + tagKey.location() + "' in '" + tagKey.registry().location() + "'"));
}

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -764,7 +_,7 @@
@@ -769,7 +_,7 @@
if (item.is(Items.WRITABLE_BOOK)) {
ItemStack itemStack = item.transmuteCopy(Items.WRITTEN_BOOK, 1);
itemStack.remove(DataComponents.WRITABLE_BOOK_CONTENT);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/net/minecraft/util/ExtraCodecs.java
+++ b/net/minecraft/util/ExtraCodecs.java
@@ -216,7 +_,7 @@
@@ -217,7 +_,7 @@
P object1 = list1.get(1);
return factory.apply(object, object1);
}), object -> ImmutableList.of(minGetter.apply((I)object), maxGetter.apply((I)object)));
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/net/minecraft/util/datafix/DataFixers.java
+++ b/net/minecraft/util/datafix/DataFixers.java
@@ -1061,7 +_,7 @@
@@ -1063,7 +_,7 @@
Schema schema161 = builder.addSchema(3086, SAME_NAMESPACED);
builder.addFixer(
new EntityVariantFix(
Expand All @@ -9,7 +9,7 @@
map5.defaultReturnValue("minecraft:tabby");
map5.put(0, "minecraft:tabby");
map5.put(1, "minecraft:black");
@@ -1098,7 +_,7 @@
@@ -1100,7 +_,7 @@
Schema schema162 = builder.addSchema(3087, SAME_NAMESPACED);
builder.addFixer(
new EntityVariantFix(
Expand Down

0 comments on commit 335bc3f

Please sign in to comment.