Skip to content

Commit 10c7f51

Browse files
Chore: Vanilla changes in 1.20.5
1 parent 0606c84 commit 10c7f51

File tree

4 files changed

+13
-11
lines changed

4 files changed

+13
-11
lines changed

.changeset/seven-colts-shave.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"CreateColonies": patch
3+
---
4+
5+
chore: 1.20.5 changes

src/main/java/nl/motionlesstrain/createcolonies/blocks/SchematicTableBlock.java

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
package nl.motionlesstrain.createcolonies.blocks;
22

33
import net.minecraft.core.BlockPos;
4-
import net.minecraft.world.InteractionHand;
54
import net.minecraft.world.InteractionResult;
65
import net.minecraft.world.MenuProvider;
76
import net.minecraft.world.entity.player.Player;
@@ -36,14 +35,12 @@ public SchematicTableBlock() {
3635
}
3736

3837
@Override
39-
@SuppressWarnings("deprecation")
40-
public @NotNull VoxelShape getShape(@NotNull BlockState state, @NotNull BlockGetter world, @NotNull BlockPos pos, @NotNull CollisionContext context) {
38+
protected @NotNull VoxelShape getShape(@NotNull BlockState state, @NotNull BlockGetter world, @NotNull BlockPos pos, @NotNull CollisionContext context) {
4139
return SHAPE;
4240
}
4341

4442
@Override
45-
@SuppressWarnings("deprecation")
46-
public @Nullable MenuProvider getMenuProvider(@NotNull BlockState any, @NotNull Level world, @NotNull BlockPos pos) {
43+
protected @Nullable MenuProvider getMenuProvider(@NotNull BlockState any, @NotNull Level world, @NotNull BlockPos pos) {
4744
final BlockEntity blockEntity = world.getBlockEntity(pos);
4845
if (blockEntity instanceof SchematicTableEntity stEntity) {
4946
return stEntity.getMenuProvider();
@@ -52,9 +49,8 @@ public SchematicTableBlock() {
5249
}
5350

5451
@Override
55-
@SuppressWarnings("deprecation")
56-
public @NotNull InteractionResult use(@NotNull BlockState state, @NotNull Level world, @NotNull BlockPos pos,
57-
@NotNull Player player, @NotNull InteractionHand hand, @NotNull BlockHitResult hitResult) {
52+
protected @NotNull InteractionResult useWithoutItem(@NotNull BlockState state, @NotNull Level world, @NotNull BlockPos pos,
53+
@NotNull Player player, @NotNull BlockHitResult hitResult) {
5854
if (!world.isClientSide()) {
5955
final BlockEntity blockEntity = world.getBlockEntity(pos);
6056
if (blockEntity instanceof SchematicTableEntity stEntity) {

src/main/java/nl/motionlesstrain/createcolonies/network/messages/SaveNBTFileMessage.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ public record SaveNBTFileMessage(String filePath, CompoundTag fileContents) impl
3434
public @NotNull Type<? extends CustomPacketPayload> type() {
3535
return TYPE;
3636
}
37-
3837
public static final StreamCodec<ByteBuf, SaveNBTFileMessage> STREAM_CODEC = StreamCodec.composite(
3938
ByteBufCodecs.STRING_UTF8,
4039
SaveNBTFileMessage::filePath,

src/main/java/nl/motionlesstrain/createcolonies/utils/datageneration/Recipes.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package nl.motionlesstrain.createcolonies.utils.datageneration;
22

33
import net.minecraft.advancements.critereon.InventoryChangeTrigger;
4+
import net.minecraft.core.HolderLookup;
45
import net.minecraft.data.DataGenerator;
56
import net.minecraft.data.PackOutput;
67
import net.minecraft.data.recipes.FinishedRecipe;
@@ -12,6 +13,7 @@
1213
import net.neoforged.neoforge.data.event.GatherDataEvent;
1314
import org.jetbrains.annotations.NotNull;
1415

16+
import java.util.concurrent.CompletableFuture;
1517
import java.util.function.Consumer;
1618

1719
import static nl.motionlesstrain.createcolonies.resources.CreateColoniesResources.Blocks.schematicTable;
@@ -25,8 +27,8 @@ public static void gatherRecipes(GatherDataEvent event) {
2527
generator.addProvider(event.includeServer(), (Factory<Recipes>)Recipes::new);
2628
}
2729

28-
public Recipes(PackOutput output) {
29-
super(output);
30+
public Recipes(PackOutput output, CompletableFuture<HolderLookup.Provider> registryAccess) {
31+
super(output, registryAccess);
3032
}
3133

3234
@Override

0 commit comments

Comments
 (0)