Commits

md_5 authored 05a38da1907
Update to Minecraft 1.18.2
No tags

nms-patches/net/minecraft/commands/arguments/blocks/ArgumentBlock.patch

Modified
1 1 --- a/net/minecraft/commands/arguments/blocks/ArgumentBlock.java
2 2 +++ b/net/minecraft/commands/arguments/blocks/ArgumentBlock.java
3 3 @@ -61,7 +61,7 @@
4 4 };
5 5 private final StringReader reader;
6 6 private final boolean forTesting;
7 7 - private final Map<IBlockState<?>, Comparable<?>> properties = Maps.newHashMap();
8 8 + private final Map<IBlockState<?>, Comparable<?>> properties = Maps.newLinkedHashMap(); // CraftBukkit - stable
9 9 private final Map<String, String> vagueProperties = Maps.newHashMap();
10 10 private MinecraftKey id = new MinecraftKey("");
11 11 private BlockStateList<Block, IBlockData> definition;
12 -@@ -237,7 +237,7 @@
12 +@@ -230,7 +230,7 @@
13 13 Iterator iterator = iblockstate.getPossibleValues().iterator();
14 14
15 15 while (iterator.hasNext()) {
16 16 - T t0 = (Comparable) iterator.next();
17 17 + T t0 = (T) iterator.next(); // CraftBukkit - decompile error
18 18
19 19 if (t0 instanceof Integer) {
20 20 suggestionsbuilder.suggest((Integer) t0);
21 -@@ -506,7 +506,7 @@
21 +@@ -493,7 +493,7 @@
22 22 Optional<T> optional = iblockstate.getValue(s);
23 23
24 24 if (optional.isPresent()) {
25 25 - this.state = (IBlockData) this.state.setValue(iblockstate, (Comparable) optional.get());
26 26 + this.state = (IBlockData) this.state.setValue(iblockstate, (T) optional.get()); // CraftBukkit - decompile error
27 27 this.properties.put(iblockstate, (Comparable) optional.get());
28 28 } else {
29 29 this.reader.setCursor(i);
30 -@@ -540,7 +540,7 @@
30 +@@ -527,7 +527,7 @@
31 31 private static <T extends Comparable<T>> void appendProperty(StringBuilder stringbuilder, IBlockState<T> iblockstate, Comparable<?> comparable) {
32 32 stringbuilder.append(iblockstate.getName());
33 33 stringbuilder.append('=');
34 34 - stringbuilder.append(iblockstate.getName(comparable));
35 35 + stringbuilder.append(iblockstate.getName((T) comparable)); // CraftBukkit - decompile error
36 36 }
37 37
38 - public CompletableFuture<Suggestions> fillSuggestions(SuggestionsBuilder suggestionsbuilder, Tags<Block> tags) {
38 + public CompletableFuture<Suggestions> fillSuggestions(SuggestionsBuilder suggestionsbuilder, IRegistry<Block> iregistry) {

Everything looks good. We'll let you know here if there's anything you should know about.

Add shortcut