Skip to content

Commit f14ad64

Browse files
Update to 1.21.11-rc2
1 parent 111be7e commit f14ad64

File tree

7 files changed

+18
-11
lines changed

7 files changed

+18
-11
lines changed

buildSrc/build.gradle.kts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,12 @@ repositories {
66
gradlePluginPortal()
77
}
88

9+
java {
10+
toolchain {
11+
languageVersion = JavaLanguageVersion.of(21)
12+
}
13+
}
14+
915
dependencies {
1016
implementation(libs.paperweight.userdev.plugin)
1117

buildSrc/src/main/kotlin/invui.common-conventions.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ dependencies {
2727
testRuntimeOnly(libs.junit.platformLauncher)
2828
testImplementation(libs.mockbukkit)
2929
testImplementation(libs.logback.classic)
30-
testImplementation(libs.paper.api)
30+
testImplementation(libs.test.paper.api)
3131
}
3232

3333
java {

gradle/libs.versions.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
[versions]
22
kotlin = "2.2.21"
3-
paper = "1.21.10-R0.1-SNAPSHOT"
3+
paper = "1.21.11-rc2-R0.1-SNAPSHOT"
4+
testpaper = "1.21.10-R0.1-SNAPSHOT"
45

56
[libraries]
67
commons-provider = { module = "xyz.xenondevs.commons:commons-provider", version = "2.0.0-alpha.8" }
@@ -13,8 +14,8 @@ kotlin-stdlib = { module = "org.jetbrains.kotlin:kotlin-stdlib", version.ref = "
1314
kotlin-test-junit = { group = "org.jetbrains.kotlin", name = "kotlin-test-junit", version.ref = "kotlin" }
1415
mockbukkit = { module = "org.mockbukkit.mockbukkit:mockbukkit-v1.21", version = "4.98.0"}
1516
logback-classic = { module = "ch.qos.logback:logback-classic", version = "1.5.21" }
16-
paper-api = { module = "io.papermc.paper:paper-api", version.ref = "paper" }
1717
paperweight-userdev-plugin = { module = "io.papermc.paperweight:paperweight-userdev", version = "2.0.0-beta.19" }
18+
test-paper-api = { module = "io.papermc.paper:paper-api", version.ref = "testpaper" }
1819

1920
[plugins]
2021
kotlin = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" }

invui/src/main/java/xyz/xenondevs/invui/internal/menu/CustomContainerMenu.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
import net.minecraft.network.protocol.common.ServerboundPongPacket;
2323
import net.minecraft.network.protocol.game.*;
2424
import net.minecraft.resources.RegistryOps;
25-
import net.minecraft.resources.ResourceLocation;
25+
import net.minecraft.resources.Identifier;
2626
import net.minecraft.server.MinecraftServer;
2727
import net.minecraft.server.level.ServerPlayer;
2828
import net.minecraft.util.HashOps;
@@ -116,7 +116,7 @@ public Integer apply(TypedDataComponent<?> typedDataComponent) {
116116
protected static final HashedStack DIRTY_MARKER = HashedStack.create(new ItemStack(
117117
BuiltInRegistries.ITEM.wrapAsHolder(Items.DIRT), 1,
118118
DataComponentPatch.builder()
119-
.set(DataComponents.ITEM_MODEL, ResourceLocation.fromNamespaceAndPath("invui", "dirty_marker"))
119+
.set(DataComponents.ITEM_MODEL, Identifier.fromNamespaceAndPath("invui", "dirty_marker"))
120120
.build()
121121
), HASH_GENERATOR);
122122

invui/src/main/java/xyz/xenondevs/invui/internal/menu/CustomMerchantMenu.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import net.minecraft.core.component.DataComponents;
66
import net.minecraft.network.protocol.game.ClientboundMerchantOffersPacket;
77
import net.minecraft.network.protocol.game.ServerboundSelectTradePacket;
8-
import net.minecraft.world.entity.npc.VillagerData;
8+
import net.minecraft.world.entity.npc.villager.VillagerData;
99
import net.minecraft.world.inventory.MenuType;
1010
import net.minecraft.world.item.ItemStack;
1111
import net.minecraft.world.item.component.CustomData;

invui/src/main/java/xyz/xenondevs/invui/internal/menu/CustomRecipeBookPoweredMenu.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import net.minecraft.network.protocol.game.ClientboundPlaceGhostRecipePacket;
77
import net.minecraft.network.protocol.game.ServerboundPlaceRecipePacket;
88
import net.minecraft.resources.ResourceKey;
9-
import net.minecraft.resources.ResourceLocation;
9+
import net.minecraft.resources.Identifier;
1010
import net.minecraft.server.MinecraftServer;
1111
import net.minecraft.world.inventory.MenuType;
1212
import net.minecraft.world.item.crafting.display.RecipeDisplayEntry;
@@ -55,7 +55,7 @@ public void handleClosed() {
5555
*/
5656
public void sendGhostRecipe(Key id) {
5757
var entryRef = new AtomicReference<@Nullable RecipeDisplayEntry>();
58-
var rk = ResourceKey.create(Registries.RECIPE, ResourceLocation.fromNamespaceAndPath(id.namespace(), id.value()));
58+
var rk = ResourceKey.create(Registries.RECIPE, Identifier.fromNamespaceAndPath(id.namespace(), id.value()));
5959
MinecraftServer.getServer().getRecipeManager().listDisplaysForRecipe(rk, entryRef::set);
6060
var entry = entryRef.get();
6161
if (entry == null)
@@ -87,7 +87,7 @@ private void handleRecipePlace(ServerboundPlaceRecipePacket packet) {
8787
var rl = displayInfo
8888
.parent()
8989
.id()
90-
.location();
90+
.identifier();
9191
var key = Key.key(rl.getNamespace(), rl.getPath());
9292
recipeSelectHandler.accept(key);
9393
}

invui/src/main/java/xyz/xenondevs/invui/internal/menu/CustomStonecutterMenu.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import net.minecraft.network.protocol.game.ClientboundContainerSetSlotPacket;
77
import net.minecraft.network.protocol.game.ClientboundUpdateRecipesPacket;
88
import net.minecraft.resources.ResourceKey;
9-
import net.minecraft.resources.ResourceLocation;
9+
import net.minecraft.resources.Identifier;
1010
import net.minecraft.server.MinecraftServer;
1111
import net.minecraft.world.inventory.MenuType;
1212
import net.minecraft.world.item.ItemStack;
@@ -128,7 +128,7 @@ private List<SelectableRecipe.SingleInputEntry<StonecutterRecipe>> createRecipes
128128
Optional.of(new RecipeHolder<>(
129129
ResourceKey.create(
130130
Registries.RECIPE,
131-
ResourceLocation.fromNamespaceAndPath("invui", "fake_stonecutter_" + MathUtils.RANDOM.nextInt())
131+
Identifier.fromNamespaceAndPath("invui", "fake_stonecutter_" + MathUtils.RANDOM.nextInt())
132132
),
133133
new StonecutterRecipe("", ingredient, button.copy())
134134
))

0 commit comments

Comments
 (0)