diff --git a/fabric-client-tags-api-v1/src/client/java/net/fabricmc/fabric/impl/tag/client/ClientTagsLoader.java b/fabric-client-tags-api-v1/src/client/java/net/fabricmc/fabric/impl/tag/client/ClientTagsLoader.java index 8746bf4be2..ccdd982493 100644 --- a/fabric-client-tags-api-v1/src/client/java/net/fabricmc/fabric/impl/tag/client/ClientTagsLoader.java +++ b/fabric-client-tags-api-v1/src/client/java/net/fabricmc/fabric/impl/tag/client/ClientTagsLoader.java @@ -80,7 +80,7 @@ public static LoadedTag loadTag(TagKey tagKey) { tagEntry.resolve(new TagEntry.ValueGetter<>() { @Nullable @Override - public Identifier direct(Identifier id) { + public Identifier direct(Identifier id, boolean required) { immediateChildIds.add(id); return id; } diff --git a/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/BiomeTagGenerator.java b/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/BiomeTagGenerator.java index b6c7b311f6..83162805a4 100644 --- a/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/BiomeTagGenerator.java +++ b/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/BiomeTagGenerator.java @@ -18,6 +18,7 @@ import java.util.concurrent.CompletableFuture; +import net.minecraft.class_10351; import net.minecraft.registry.RegistryKeys; import net.minecraft.registry.RegistryWrapper; import net.minecraft.registry.tag.BiomeTags; @@ -94,6 +95,9 @@ private void generateCategoryTags() { getOrCreateTagBuilder(ConventionalBiomeTags.IS_BIRCH_FOREST) .add(BiomeKeys.BIRCH_FOREST) .add(BiomeKeys.OLD_GROWTH_BIRCH_FOREST); + getOrCreateTagBuilder(ConventionalBiomeTags.IS_DARK_FOREST) + .add(BiomeKeys.DARK_FOREST) + .addOptional(class_10351.PALE_GARDEN); getOrCreateTagBuilder(ConventionalBiomeTags.IS_OCEAN) .addOptionalTag(BiomeTags.IS_OCEAN) .addOptionalTag(ConventionalBiomeTags.IS_DEEP_OCEAN) @@ -175,6 +179,7 @@ private void generateClimateAndVegetationTags() { .add(BiomeKeys.SWAMP) .add(BiomeKeys.STONY_SHORE) .add(BiomeKeys.DARK_FOREST) + .addOptional(class_10351.PALE_GARDEN) .add(BiomeKeys.WINDSWEPT_FOREST) .add(BiomeKeys.BIRCH_FOREST) .add(BiomeKeys.OLD_GROWTH_BIRCH_FOREST) @@ -247,6 +252,7 @@ private void generateClimateAndVegetationTags() { getOrCreateTagBuilder(ConventionalBiomeTags.IS_VEGETATION_DENSE_OVERWORLD) .add(BiomeKeys.DARK_FOREST) + .addOptional(class_10351.PALE_GARDEN) .add(BiomeKeys.OLD_GROWTH_BIRCH_FOREST) .add(BiomeKeys.OLD_GROWTH_SPRUCE_TAIGA) .add(BiomeKeys.JUNGLE) @@ -279,6 +285,7 @@ private void generateClimateAndVegetationTags() { .add(BiomeKeys.FLOWER_FOREST) .add(BiomeKeys.BIRCH_FOREST) .add(BiomeKeys.DARK_FOREST) + .addOptional(class_10351.PALE_GARDEN) .add(BiomeKeys.OLD_GROWTH_BIRCH_FOREST); getOrCreateTagBuilder(ConventionalBiomeTags.IS_JUNGLE_TREE) .addOptionalTag(ConventionalBiomeTags.IS_JUNGLE); diff --git a/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/EnglishTagLangGenerator.java b/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/EnglishTagLangGenerator.java index a93520876c..85ab508ef3 100644 --- a/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/EnglishTagLangGenerator.java +++ b/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/EnglishTagLangGenerator.java @@ -385,6 +385,7 @@ public void generateTranslations(RegistryWrapper.WrapperLookup registryLookup, T translationBuilder.add(ConventionalBiomeTags.IS_SNOWY_PLAINS, "Snowy Plains"); translationBuilder.add(ConventionalBiomeTags.IS_FOREST, "Forest"); translationBuilder.add(ConventionalBiomeTags.IS_BIRCH_FOREST, "Birch Forest"); + translationBuilder.add(ConventionalBiomeTags.IS_DARK_FOREST, "Dark Forest"); translationBuilder.add(ConventionalBiomeTags.IS_FLOWER_FOREST, "Flower Forest"); translationBuilder.add(ConventionalBiomeTags.IS_TAIGA, "Taiga"); translationBuilder.add(ConventionalBiomeTags.IS_OLD_GROWTH, "Old Growth"); diff --git a/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/EntityTypeTagGenerator.java b/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/EntityTypeTagGenerator.java index d025f0e7e0..fa38740c25 100644 --- a/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/EntityTypeTagGenerator.java +++ b/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/EntityTypeTagGenerator.java @@ -52,6 +52,7 @@ protected void configure(RegistryWrapper.WrapperLookup registries) { .add(EntityType.JUNGLE_CHEST_BOAT) .add(EntityType.ACACIA_CHEST_BOAT) .add(EntityType.CHERRY_CHEST_BOAT) + .add(EntityType.PALE_OAK_CHEST_BOAT) .add(EntityType.DARK_OAK_CHEST_BOAT) .add(EntityType.MANGROVE_CHEST_BOAT) .add(EntityType.BAMBOO_CHEST_RAFT); diff --git a/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/ItemTagGenerator.java b/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/ItemTagGenerator.java index 111a0bf2ae..47f7b228e5 100644 --- a/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/ItemTagGenerator.java +++ b/fabric-convention-tags-v2/src/datagen/java/net/fabricmc/fabric/impl/tag/convention/datagen/generators/ItemTagGenerator.java @@ -772,97 +772,97 @@ private void generateDyedTags() { .add(Items.BLACK_BANNER).add(Items.BLACK_BED).add(Items.BLACK_CANDLE).add(Items.BLACK_CARPET) .add(Items.BLACK_CONCRETE).add(Items.BLACK_CONCRETE_POWDER).add(Items.BLACK_GLAZED_TERRACOTTA) .add(Items.BLACK_SHULKER_BOX).add(Items.BLACK_STAINED_GLASS).add(Items.BLACK_STAINED_GLASS_PANE) - .add(Items.BLACK_TERRACOTTA).add(Items.BLACK_WOOL); + .add(Items.BLACK_TERRACOTTA).add(Items.BLACK_WOOL).add(Items.BLACK_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.BLUE_DYED) .add(Items.BLUE_BANNER).add(Items.BLUE_BED).add(Items.BLUE_CANDLE).add(Items.BLUE_CARPET) .add(Items.BLUE_CONCRETE).add(Items.BLUE_CONCRETE_POWDER).add(Items.BLUE_GLAZED_TERRACOTTA) .add(Items.BLUE_SHULKER_BOX).add(Items.BLUE_STAINED_GLASS).add(Items.BLUE_STAINED_GLASS_PANE) - .add(Items.BLUE_TERRACOTTA).add(Items.BLUE_WOOL); + .add(Items.BLUE_TERRACOTTA).add(Items.BLUE_WOOL).add(Items.BLUE_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.BROWN_DYED) .add(Items.BROWN_BANNER).add(Items.BROWN_BED).add(Items.BROWN_CANDLE).add(Items.BROWN_CARPET) .add(Items.BROWN_CONCRETE).add(Items.BROWN_CONCRETE_POWDER).add(Items.BROWN_GLAZED_TERRACOTTA) .add(Items.BROWN_SHULKER_BOX).add(Items.BROWN_STAINED_GLASS).add(Items.BROWN_STAINED_GLASS_PANE) - .add(Items.BROWN_TERRACOTTA).add(Items.BROWN_WOOL); + .add(Items.BROWN_TERRACOTTA).add(Items.BROWN_WOOL).add(Items.BROWN_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.CYAN_DYED) .add(Items.CYAN_BANNER).add(Items.CYAN_BED).add(Items.CYAN_CANDLE).add(Items.CYAN_CARPET) .add(Items.CYAN_CONCRETE).add(Items.CYAN_CONCRETE_POWDER).add(Items.CYAN_GLAZED_TERRACOTTA) .add(Items.CYAN_SHULKER_BOX).add(Items.CYAN_STAINED_GLASS).add(Items.CYAN_STAINED_GLASS_PANE) - .add(Items.CYAN_TERRACOTTA).add(Items.CYAN_WOOL); + .add(Items.CYAN_TERRACOTTA).add(Items.CYAN_WOOL).add(Items.CYAN_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.GRAY_DYED) .add(Items.GRAY_BANNER).add(Items.GRAY_BED).add(Items.GRAY_CANDLE).add(Items.GRAY_CARPET) .add(Items.GRAY_CONCRETE).add(Items.GRAY_CONCRETE_POWDER).add(Items.GRAY_GLAZED_TERRACOTTA) .add(Items.GRAY_SHULKER_BOX).add(Items.GRAY_STAINED_GLASS).add(Items.GRAY_STAINED_GLASS_PANE) - .add(Items.GRAY_TERRACOTTA).add(Items.GRAY_WOOL); + .add(Items.GRAY_TERRACOTTA).add(Items.GRAY_WOOL).add(Items.GRAY_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.GREEN_DYED) .add(Items.GREEN_BANNER).add(Items.GREEN_BED).add(Items.GREEN_CANDLE).add(Items.GREEN_CARPET) .add(Items.GREEN_CONCRETE).add(Items.GREEN_CONCRETE_POWDER).add(Items.GREEN_GLAZED_TERRACOTTA) .add(Items.GREEN_SHULKER_BOX).add(Items.GREEN_STAINED_GLASS).add(Items.GREEN_STAINED_GLASS_PANE) - .add(Items.GREEN_TERRACOTTA).add(Items.GREEN_WOOL); + .add(Items.GREEN_TERRACOTTA).add(Items.GREEN_WOOL).add(Items.GREEN_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.LIGHT_BLUE_DYED) .add(Items.LIGHT_BLUE_BANNER).add(Items.LIGHT_BLUE_BED).add(Items.LIGHT_BLUE_CANDLE).add(Items.LIGHT_BLUE_CARPET) .add(Items.LIGHT_BLUE_CONCRETE).add(Items.LIGHT_BLUE_CONCRETE_POWDER).add(Items.LIGHT_BLUE_GLAZED_TERRACOTTA) .add(Items.LIGHT_BLUE_SHULKER_BOX).add(Items.LIGHT_BLUE_STAINED_GLASS).add(Items.LIGHT_BLUE_STAINED_GLASS_PANE) - .add(Items.LIGHT_BLUE_TERRACOTTA).add(Items.LIGHT_BLUE_WOOL); + .add(Items.LIGHT_BLUE_TERRACOTTA).add(Items.LIGHT_BLUE_WOOL).add(Items.LIGHT_BLUE_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.LIGHT_GRAY_DYED) .add(Items.LIGHT_GRAY_BANNER).add(Items.LIGHT_GRAY_BED).add(Items.LIGHT_GRAY_CANDLE).add(Items.LIGHT_GRAY_CARPET) .add(Items.LIGHT_GRAY_CONCRETE).add(Items.LIGHT_GRAY_CONCRETE_POWDER).add(Items.LIGHT_GRAY_GLAZED_TERRACOTTA) .add(Items.LIGHT_GRAY_SHULKER_BOX).add(Items.LIGHT_GRAY_STAINED_GLASS).add(Items.LIGHT_GRAY_STAINED_GLASS_PANE) - .add(Items.LIGHT_GRAY_TERRACOTTA).add(Items.LIGHT_GRAY_WOOL); + .add(Items.LIGHT_GRAY_TERRACOTTA).add(Items.LIGHT_GRAY_WOOL).add(Items.LIGHT_GRAY_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.LIME_DYED) .add(Items.LIME_BANNER).add(Items.LIME_BED).add(Items.LIME_CANDLE).add(Items.LIME_CARPET) .add(Items.LIME_CONCRETE).add(Items.LIME_CONCRETE_POWDER).add(Items.LIME_GLAZED_TERRACOTTA) .add(Items.LIME_SHULKER_BOX).add(Items.LIME_STAINED_GLASS).add(Items.LIME_STAINED_GLASS_PANE) - .add(Items.LIME_TERRACOTTA).add(Items.LIME_WOOL); + .add(Items.LIME_TERRACOTTA).add(Items.LIME_WOOL).add(Items.LIME_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.MAGENTA_DYED) .add(Items.MAGENTA_BANNER).add(Items.MAGENTA_BED).add(Items.MAGENTA_CANDLE).add(Items.MAGENTA_CARPET) .add(Items.MAGENTA_CONCRETE).add(Items.MAGENTA_CONCRETE_POWDER).add(Items.MAGENTA_GLAZED_TERRACOTTA) .add(Items.MAGENTA_SHULKER_BOX).add(Items.MAGENTA_STAINED_GLASS).add(Items.MAGENTA_STAINED_GLASS_PANE) - .add(Items.MAGENTA_TERRACOTTA).add(Items.MAGENTA_WOOL); + .add(Items.MAGENTA_TERRACOTTA).add(Items.MAGENTA_WOOL).add(Items.MAGENTA_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.ORANGE_DYED) .add(Items.ORANGE_BANNER).add(Items.ORANGE_BED).add(Items.ORANGE_CANDLE).add(Items.ORANGE_CARPET) .add(Items.ORANGE_CONCRETE).add(Items.ORANGE_CONCRETE_POWDER).add(Items.ORANGE_GLAZED_TERRACOTTA) .add(Items.ORANGE_SHULKER_BOX).add(Items.ORANGE_STAINED_GLASS).add(Items.ORANGE_STAINED_GLASS_PANE) - .add(Items.ORANGE_TERRACOTTA).add(Items.ORANGE_WOOL); + .add(Items.ORANGE_TERRACOTTA).add(Items.ORANGE_WOOL).add(Items.ORANGE_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.PINK_DYED) .add(Items.PINK_BANNER).add(Items.PINK_BED).add(Items.PINK_CANDLE).add(Items.PINK_CARPET) .add(Items.PINK_CONCRETE).add(Items.PINK_CONCRETE_POWDER).add(Items.PINK_GLAZED_TERRACOTTA) .add(Items.PINK_SHULKER_BOX).add(Items.PINK_STAINED_GLASS).add(Items.PINK_STAINED_GLASS_PANE) - .add(Items.PINK_TERRACOTTA).add(Items.PINK_WOOL); + .add(Items.PINK_TERRACOTTA).add(Items.PINK_WOOL).add(Items.PINK_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.PURPLE_DYED) .add(Items.PURPLE_BANNER).add(Items.PURPLE_BED).add(Items.PURPLE_CANDLE).add(Items.PURPLE_CARPET) .add(Items.PURPLE_CONCRETE).add(Items.PURPLE_CONCRETE_POWDER).add(Items.PURPLE_GLAZED_TERRACOTTA) .add(Items.PURPLE_SHULKER_BOX).add(Items.PURPLE_STAINED_GLASS).add(Items.PURPLE_STAINED_GLASS_PANE) - .add(Items.PURPLE_TERRACOTTA).add(Items.PURPLE_WOOL); + .add(Items.PURPLE_TERRACOTTA).add(Items.PURPLE_WOOL).add(Items.PURPLE_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.RED_DYED) .add(Items.RED_BANNER).add(Items.RED_BED).add(Items.RED_CANDLE).add(Items.RED_CARPET) .add(Items.RED_CONCRETE).add(Items.RED_CONCRETE_POWDER).add(Items.RED_GLAZED_TERRACOTTA) .add(Items.RED_SHULKER_BOX).add(Items.RED_STAINED_GLASS).add(Items.RED_STAINED_GLASS_PANE) - .add(Items.RED_TERRACOTTA).add(Items.RED_WOOL); + .add(Items.RED_TERRACOTTA).add(Items.RED_WOOL).add(Items.RED_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.WHITE_DYED) .add(Items.WHITE_BANNER).add(Items.WHITE_BED).add(Items.WHITE_CANDLE).add(Items.WHITE_CARPET) .add(Items.WHITE_CONCRETE).add(Items.WHITE_CONCRETE_POWDER).add(Items.WHITE_GLAZED_TERRACOTTA) .add(Items.WHITE_SHULKER_BOX).add(Items.WHITE_STAINED_GLASS).add(Items.WHITE_STAINED_GLASS_PANE) - .add(Items.WHITE_TERRACOTTA).add(Items.WHITE_WOOL); + .add(Items.WHITE_TERRACOTTA).add(Items.WHITE_WOOL).add(Items.WHITE_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.YELLOW_DYED) .add(Items.YELLOW_BANNER).add(Items.YELLOW_BED).add(Items.YELLOW_CANDLE).add(Items.YELLOW_CARPET) .add(Items.YELLOW_CONCRETE).add(Items.YELLOW_CONCRETE_POWDER).add(Items.YELLOW_GLAZED_TERRACOTTA) .add(Items.YELLOW_SHULKER_BOX).add(Items.YELLOW_STAINED_GLASS).add(Items.YELLOW_STAINED_GLASS_PANE) - .add(Items.YELLOW_TERRACOTTA).add(Items.YELLOW_WOOL); + .add(Items.YELLOW_TERRACOTTA).add(Items.YELLOW_WOOL).add(Items.YELLOW_BUNDLE); getOrCreateTagBuilder(ConventionalItemTags.DYED) .addTag(ConventionalItemTags.WHITE_DYED) diff --git a/fabric-convention-tags-v2/src/generated/resources/assets/fabric-convention-tags-v2/lang/en_us.json b/fabric-convention-tags-v2/src/generated/resources/assets/fabric-convention-tags-v2/lang/en_us.json index 058d1ddaaa..de61805cf7 100644 --- a/fabric-convention-tags-v2/src/generated/resources/assets/fabric-convention-tags-v2/lang/en_us.json +++ b/fabric-convention-tags-v2/src/generated/resources/assets/fabric-convention-tags-v2/lang/en_us.json @@ -309,6 +309,7 @@ "tag.worldgen.biome.c.is_cold": "Cold", "tag.worldgen.biome.c.is_cold.end": "Cold End", "tag.worldgen.biome.c.is_cold.overworld": "Cold Overworld", + "tag.worldgen.biome.c.is_dark_forest": "Dark Forest", "tag.worldgen.biome.c.is_dead": "Dead", "tag.worldgen.biome.c.is_deep_ocean": "Deep Ocean", "tag.worldgen.biome.c.is_dense_vegetation": "Dense Vegetation", diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/entity_type/boats.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/entity_type/boats.json index ec9bdf7bb8..04ad21cb21 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/entity_type/boats.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/entity_type/boats.json @@ -10,6 +10,7 @@ "minecraft:jungle_chest_boat", "minecraft:acacia_chest_boat", "minecraft:cherry_chest_boat", + "minecraft:pale_oak_chest_boat", "minecraft:dark_oak_chest_boat", "minecraft:mangrove_chest_boat", "minecraft:bamboo_chest_raft" diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/black.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/black.json index 174ba5e3c4..fc820d59fd 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/black.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/black.json @@ -11,6 +11,7 @@ "minecraft:black_stained_glass", "minecraft:black_stained_glass_pane", "minecraft:black_terracotta", - "minecraft:black_wool" + "minecraft:black_wool", + "minecraft:black_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/blue.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/blue.json index ca4b83cd7d..f034028a61 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/blue.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/blue.json @@ -11,6 +11,7 @@ "minecraft:blue_stained_glass", "minecraft:blue_stained_glass_pane", "minecraft:blue_terracotta", - "minecraft:blue_wool" + "minecraft:blue_wool", + "minecraft:blue_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/brown.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/brown.json index 502f5bccec..de120d0b68 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/brown.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/brown.json @@ -11,6 +11,7 @@ "minecraft:brown_stained_glass", "minecraft:brown_stained_glass_pane", "minecraft:brown_terracotta", - "minecraft:brown_wool" + "minecraft:brown_wool", + "minecraft:brown_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/cyan.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/cyan.json index f3e0d24c65..44ca61474b 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/cyan.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/cyan.json @@ -11,6 +11,7 @@ "minecraft:cyan_stained_glass", "minecraft:cyan_stained_glass_pane", "minecraft:cyan_terracotta", - "minecraft:cyan_wool" + "minecraft:cyan_wool", + "minecraft:cyan_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/gray.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/gray.json index 58a9ff3549..a3e510aaba 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/gray.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/gray.json @@ -11,6 +11,7 @@ "minecraft:gray_stained_glass", "minecraft:gray_stained_glass_pane", "minecraft:gray_terracotta", - "minecraft:gray_wool" + "minecraft:gray_wool", + "minecraft:gray_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/green.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/green.json index 27dc841609..04e53a8eee 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/green.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/green.json @@ -11,6 +11,7 @@ "minecraft:green_stained_glass", "minecraft:green_stained_glass_pane", "minecraft:green_terracotta", - "minecraft:green_wool" + "minecraft:green_wool", + "minecraft:green_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/light_blue.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/light_blue.json index 63e842c4e0..1ad93369ae 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/light_blue.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/light_blue.json @@ -11,6 +11,7 @@ "minecraft:light_blue_stained_glass", "minecraft:light_blue_stained_glass_pane", "minecraft:light_blue_terracotta", - "minecraft:light_blue_wool" + "minecraft:light_blue_wool", + "minecraft:light_blue_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/light_gray.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/light_gray.json index 5a46bc1a15..36e12e6b79 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/light_gray.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/light_gray.json @@ -11,6 +11,7 @@ "minecraft:light_gray_stained_glass", "minecraft:light_gray_stained_glass_pane", "minecraft:light_gray_terracotta", - "minecraft:light_gray_wool" + "minecraft:light_gray_wool", + "minecraft:light_gray_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/lime.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/lime.json index 56f424525c..1f9b6ca853 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/lime.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/lime.json @@ -11,6 +11,7 @@ "minecraft:lime_stained_glass", "minecraft:lime_stained_glass_pane", "minecraft:lime_terracotta", - "minecraft:lime_wool" + "minecraft:lime_wool", + "minecraft:lime_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/magenta.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/magenta.json index f837aefc8a..39acace941 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/magenta.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/magenta.json @@ -11,6 +11,7 @@ "minecraft:magenta_stained_glass", "minecraft:magenta_stained_glass_pane", "minecraft:magenta_terracotta", - "minecraft:magenta_wool" + "minecraft:magenta_wool", + "minecraft:magenta_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/orange.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/orange.json index 7fa2a7ef84..74d5a1548e 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/orange.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/orange.json @@ -11,6 +11,7 @@ "minecraft:orange_stained_glass", "minecraft:orange_stained_glass_pane", "minecraft:orange_terracotta", - "minecraft:orange_wool" + "minecraft:orange_wool", + "minecraft:orange_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/pink.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/pink.json index 7538cceb02..5b16700012 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/pink.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/pink.json @@ -11,6 +11,7 @@ "minecraft:pink_stained_glass", "minecraft:pink_stained_glass_pane", "minecraft:pink_terracotta", - "minecraft:pink_wool" + "minecraft:pink_wool", + "minecraft:pink_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/purple.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/purple.json index 61355c9ae2..5475a29dfd 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/purple.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/purple.json @@ -11,6 +11,7 @@ "minecraft:purple_stained_glass", "minecraft:purple_stained_glass_pane", "minecraft:purple_terracotta", - "minecraft:purple_wool" + "minecraft:purple_wool", + "minecraft:purple_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/red.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/red.json index 252f4660e0..f5bdbea7f9 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/red.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/red.json @@ -11,6 +11,7 @@ "minecraft:red_stained_glass", "minecraft:red_stained_glass_pane", "minecraft:red_terracotta", - "minecraft:red_wool" + "minecraft:red_wool", + "minecraft:red_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/white.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/white.json index 2e1979e814..97860b516b 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/white.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/white.json @@ -11,6 +11,7 @@ "minecraft:white_stained_glass", "minecraft:white_stained_glass_pane", "minecraft:white_terracotta", - "minecraft:white_wool" + "minecraft:white_wool", + "minecraft:white_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/yellow.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/yellow.json index 0e353cc64e..1b07be0132 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/yellow.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/item/dyed/yellow.json @@ -11,6 +11,7 @@ "minecraft:yellow_stained_glass", "minecraft:yellow_stained_glass_pane", "minecraft:yellow_terracotta", - "minecraft:yellow_wool" + "minecraft:yellow_wool", + "minecraft:yellow_bundle" ] } \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_dark_forest.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_dark_forest.json new file mode 100644 index 0000000000..a487891a3c --- /dev/null +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_dark_forest.json @@ -0,0 +1,9 @@ +{ + "values": [ + "minecraft:dark_forest", + { + "id": "minecraft:pale_garden", + "required": false + } + ] +} \ No newline at end of file diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_dense_vegetation/overworld.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_dense_vegetation/overworld.json index 7e1e45b9ec..260e105f44 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_dense_vegetation/overworld.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_dense_vegetation/overworld.json @@ -1,6 +1,10 @@ { "values": [ "minecraft:dark_forest", + { + "id": "minecraft:pale_garden", + "required": false + }, "minecraft:old_growth_birch_forest", "minecraft:old_growth_spruce_taiga", "minecraft:jungle", diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_temperate/overworld.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_temperate/overworld.json index b1c4877cac..8d1b333679 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_temperate/overworld.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_temperate/overworld.json @@ -5,6 +5,10 @@ "minecraft:swamp", "minecraft:stony_shore", "minecraft:dark_forest", + { + "id": "minecraft:pale_garden", + "required": false + }, "minecraft:windswept_forest", "minecraft:birch_forest", "minecraft:old_growth_birch_forest", diff --git a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_tree/deciduous.json b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_tree/deciduous.json index 726da77bf5..cf61c99b6a 100644 --- a/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_tree/deciduous.json +++ b/fabric-convention-tags-v2/src/generated/resources/data/c/tags/worldgen/biome/is_tree/deciduous.json @@ -5,6 +5,10 @@ "minecraft:flower_forest", "minecraft:birch_forest", "minecraft:dark_forest", + { + "id": "minecraft:pale_garden", + "required": false + }, "minecraft:old_growth_birch_forest", { "id": "#c:tree_deciduous", diff --git a/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/api/tag/convention/v2/ConventionalBiomeTags.java b/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/api/tag/convention/v2/ConventionalBiomeTags.java index a05b7d9ead..2a25983986 100644 --- a/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/api/tag/convention/v2/ConventionalBiomeTags.java +++ b/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/api/tag/convention/v2/ConventionalBiomeTags.java @@ -104,6 +104,7 @@ private ConventionalBiomeTags() { */ public static final TagKey IS_FOREST = register("is_forest"); public static final TagKey IS_BIRCH_FOREST = register("is_birch_forest"); + public static final TagKey IS_DARK_FOREST = register("is_dark_forest"); public static final TagKey IS_FLOWER_FOREST = register("is_flower_forest"); public static final TagKey IS_TAIGA = register("is_taiga"); public static final TagKey IS_OLD_GROWTH = register("is_old_growth"); diff --git a/fabric-data-generation-api-v1/src/main/java/net/fabricmc/fabric/api/datagen/v1/provider/FabricRecipeProvider.java b/fabric-data-generation-api-v1/src/main/java/net/fabricmc/fabric/api/datagen/v1/provider/FabricRecipeProvider.java index 8579f23754..da8b446850 100644 --- a/fabric-data-generation-api-v1/src/main/java/net/fabricmc/fabric/api/datagen/v1/provider/FabricRecipeProvider.java +++ b/fabric-data-generation-api-v1/src/main/java/net/fabricmc/fabric/api/datagen/v1/provider/FabricRecipeProvider.java @@ -39,6 +39,7 @@ import net.minecraft.data.server.recipe.ShapedRecipeJsonBuilder; import net.minecraft.data.server.recipe.ShapelessRecipeJsonBuilder; import net.minecraft.recipe.Recipe; +import net.minecraft.registry.RegistryKey; import net.minecraft.registry.RegistryKeys; import net.minecraft.registry.RegistryOps; import net.minecraft.registry.RegistryWrapper; @@ -77,9 +78,9 @@ protected RecipeExporter withConditions(RecipeExporter exporter, ResourceConditi Preconditions.checkArgument(conditions.length > 0, "Must add at least one condition."); return new RecipeExporter() { @Override - public void accept(Identifier identifier, Recipe recipe, @Nullable AdvancementEntry advancementEntry) { + public void accept(RegistryKey> key, Recipe recipe, @Nullable AdvancementEntry advancementEntry) { FabricDataGenHelper.addConditions(recipe, conditions); - exporter.accept(identifier, recipe, advancementEntry); + exporter.accept(key, recipe, advancementEntry); } @Override @@ -100,8 +101,8 @@ public CompletableFuture run(DataWriter writer) { List> list = new ArrayList<>(); RecipeGenerator recipeGenerator = getRecipeGenerator(wrapperLookup, new RecipeExporter() { @Override - public void accept(Identifier recipeId, Recipe recipe, @Nullable AdvancementEntry advancement) { - Identifier identifier = getRecipeIdentifier(recipeId); + public void accept(RegistryKey> recipeKey, Recipe recipe, @Nullable AdvancementEntry advancement) { + Identifier identifier = getRecipeIdentifier(recipeKey.getValue()); if (!generatedRecipes.add(identifier)) { throw new IllegalStateException("Duplicate recipe " + identifier); diff --git a/fabric-data-generation-api-v1/src/main/resources/fabric-data-generation-api-v1.accesswidener b/fabric-data-generation-api-v1/src/main/resources/fabric-data-generation-api-v1.accesswidener index be4e30fe78..5d76d59e1f 100644 --- a/fabric-data-generation-api-v1/src/main/resources/fabric-data-generation-api-v1.accesswidener +++ b/fabric-data-generation-api-v1/src/main/resources/fabric-data-generation-api-v1.accesswidener @@ -64,7 +64,7 @@ transitive-accessible method net/minecraft/data/server/recipe/RecipeGenerator of transitive-accessible method net/minecraft/data/server/recipe/RecipeGenerator offerBlasting (Ljava/util/List;Lnet/minecraft/recipe/book/RecipeCategory;Lnet/minecraft/item/ItemConvertible;FILjava/lang/String;)V transitive-accessible method net/minecraft/data/server/recipe/RecipeGenerator offerMultipleOptions (Lnet/minecraft/recipe/RecipeSerializer;Lnet/minecraft/recipe/AbstractCookingRecipe$RecipeFactory;Ljava/util/List;Lnet/minecraft/recipe/book/RecipeCategory;Lnet/minecraft/item/ItemConvertible;FILjava/lang/String;Ljava/lang/String;)V transitive-accessible method net/minecraft/data/server/recipe/RecipeGenerator offerNetheriteUpgradeRecipe (Lnet/minecraft/item/Item;Lnet/minecraft/recipe/book/RecipeCategory;Lnet/minecraft/item/Item;)V -transitive-accessible method net/minecraft/data/server/recipe/RecipeGenerator offerSmithingTrimRecipe (Lnet/minecraft/item/Item;Lnet/minecraft/util/Identifier;)V +transitive-accessible method net/minecraft/data/server/recipe/RecipeGenerator offerSmithingTrimRecipe (Lnet/minecraft/item/Item;Lnet/minecraft/registry/RegistryKey;)V transitive-accessible method net/minecraft/data/server/recipe/RecipeGenerator offer2x2CompactingRecipe (Lnet/minecraft/recipe/book/RecipeCategory;Lnet/minecraft/item/ItemConvertible;Lnet/minecraft/item/ItemConvertible;)V transitive-accessible method net/minecraft/data/server/recipe/RecipeGenerator offerCompactingRecipe (Lnet/minecraft/recipe/book/RecipeCategory;Lnet/minecraft/item/ItemConvertible;Lnet/minecraft/item/ItemConvertible;Ljava/lang/String;)V transitive-accessible method net/minecraft/data/server/recipe/RecipeGenerator offerCompactingRecipe (Lnet/minecraft/recipe/book/RecipeCategory;Lnet/minecraft/item/ItemConvertible;Lnet/minecraft/item/ItemConvertible;)V @@ -178,6 +178,7 @@ transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator registerNorthDefaultHorizontalRotated (Lnet/minecraft/block/Block;Lnet/minecraft/data/client/TexturedModel$Factory;)V transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator createAxisRotatedBlockState (Lnet/minecraft/block/Block;Lnet/minecraft/util/Identifier;Lnet/minecraft/util/Identifier;)Lnet/minecraft/data/client/BlockStateSupplier; transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator registerAxisRotated (Lnet/minecraft/block/Block;Lnet/minecraft/data/client/TexturedModel$Factory;Lnet/minecraft/data/client/TexturedModel$Factory;)V +transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator method_64949 (Lnet/minecraft/block/Block;)V transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator createSubModel (Lnet/minecraft/block/Block;Ljava/lang/String;Lnet/minecraft/data/client/Model;Ljava/util/function/Function;)Lnet/minecraft/util/Identifier; transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator createPressurePlateBlockState (Lnet/minecraft/block/Block;Lnet/minecraft/util/Identifier;Lnet/minecraft/util/Identifier;)Lnet/minecraft/data/client/BlockStateSupplier; transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator createSlabBlockState (Lnet/minecraft/block/Block;Lnet/minecraft/util/Identifier;Lnet/minecraft/util/Identifier;Lnet/minecraft/util/Identifier;)Lnet/minecraft/data/client/BlockStateSupplier; @@ -249,6 +250,8 @@ transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator getTurtleEggModel (ILjava/lang/String;Lnet/minecraft/data/client/TextureMap;)Lnet/minecraft/util/Identifier; transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator getTurtleEggModel (Ljava/lang/Integer;Ljava/lang/Integer;)Lnet/minecraft/util/Identifier; transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator registerWallPlant (Lnet/minecraft/block/Block;)V +transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator method_64940 (Lnet/minecraft/block/Block;)V +transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator method_64941 (Lnet/minecraft/block/Block;)V transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator supplyChiseledBookshelfModels (Lnet/minecraft/data/client/MultipartBlockStateSupplier;Lnet/minecraft/data/client/When$PropertyCondition;Lnet/minecraft/data/client/VariantSettings$Rotation;)V transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator supplyChiseledBookshelfModel (Lnet/minecraft/data/client/MultipartBlockStateSupplier;Lnet/minecraft/data/client/When$PropertyCondition;Lnet/minecraft/data/client/VariantSettings$Rotation;Lnet/minecraft/state/property/BooleanProperty;Lnet/minecraft/data/client/Model;Z)V transitive-accessible method net/minecraft/data/client/BlockStateModelGenerator registerShulkerBox (Lnet/minecraft/block/Block;)V @@ -289,6 +292,7 @@ transitive-accessible method net/minecraft/data/server/loottable/BlockLootTableG transitive-accessible method net/minecraft/data/server/loottable/BlockLootTableGenerator shortPlantDrops (Lnet/minecraft/block/Block;)Lnet/minecraft/loot/LootTable$Builder; transitive-accessible method net/minecraft/data/server/loottable/BlockLootTableGenerator dropsWithShears (Lnet/minecraft/item/ItemConvertible;)Lnet/minecraft/loot/LootTable$Builder; transitive-accessible method net/minecraft/data/server/loottable/BlockLootTableGenerator multifaceGrowthDrops (Lnet/minecraft/block/Block;Lnet/minecraft/loot/condition/LootCondition$Builder;)Lnet/minecraft/loot/LootTable$Builder; +transitive-accessible method net/minecraft/data/server/loottable/BlockLootTableGenerator method_64930 (Lnet/minecraft/block/Block;)Lnet/minecraft/loot/LootTable$Builder; transitive-accessible method net/minecraft/data/server/loottable/BlockLootTableGenerator leavesDrops (Lnet/minecraft/block/Block;Lnet/minecraft/block/Block;[F)Lnet/minecraft/loot/LootTable$Builder; transitive-accessible method net/minecraft/data/server/loottable/BlockLootTableGenerator oakLeavesDrops (Lnet/minecraft/block/Block;Lnet/minecraft/block/Block;[F)Lnet/minecraft/loot/LootTable$Builder; transitive-accessible method net/minecraft/data/server/loottable/BlockLootTableGenerator mangroveLeavesDrops (Lnet/minecraft/block/Block;)Lnet/minecraft/loot/LootTable$Builder; diff --git a/fabric-dimensions-v1/src/testmod/java/net/fabricmc/fabric/test/dimension/VoidChunkGenerator.java b/fabric-dimensions-v1/src/testmod/java/net/fabricmc/fabric/test/dimension/VoidChunkGenerator.java index a93eb332c8..e59e2e9296 100644 --- a/fabric-dimensions-v1/src/testmod/java/net/fabricmc/fabric/test/dimension/VoidChunkGenerator.java +++ b/fabric-dimensions-v1/src/testmod/java/net/fabricmc/fabric/test/dimension/VoidChunkGenerator.java @@ -98,6 +98,6 @@ public VerticalBlockSample getColumnSample(int x, int z, HeightLimitView heightL } @Override - public void getDebugHudText(List list, NoiseConfig noiseConfig, BlockPos blockPos) { + public void appendDebugHudText(List list, NoiseConfig noiseConfig, BlockPos blockPos) { } } diff --git a/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/api/item/v1/FabricItem.java b/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/api/item/v1/FabricItem.java index ce6284890d..94e29787aa 100644 --- a/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/api/item/v1/FabricItem.java +++ b/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/api/item/v1/FabricItem.java @@ -92,7 +92,7 @@ default boolean allowContinuingBlockBreaking(PlayerEntity player, ItemStack oldS * @return the leftover item stack */ default ItemStack getRecipeRemainder(ItemStack stack) { - return ((Item) this).hasRecipeRemainder() ? ((Item) this).getRecipeRemainder().getDefaultStack() : ItemStack.EMPTY; + return ((Item) this).getRecipeRemainder(); } /** diff --git a/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/AbstractFurnaceBlockEntityMixin.java b/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/AbstractFurnaceBlockEntityMixin.java index 680f710ba7..1a2b3b365f 100644 --- a/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/AbstractFurnaceBlockEntityMixin.java +++ b/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/AbstractFurnaceBlockEntityMixin.java @@ -28,8 +28,9 @@ import net.minecraft.block.entity.AbstractFurnaceBlockEntity; import net.minecraft.item.ItemStack; import net.minecraft.recipe.RecipeEntry; +import net.minecraft.recipe.input.SingleStackRecipeInput; +import net.minecraft.server.world.ServerWorld; import net.minecraft.util.math.BlockPos; -import net.minecraft.world.World; @Mixin(AbstractFurnaceBlockEntity.class) public abstract class AbstractFurnaceBlockEntityMixin { @@ -37,7 +38,7 @@ public abstract class AbstractFurnaceBlockEntityMixin { private static final ThreadLocal REMAINDER_STACK = new ThreadLocal<>(); @Inject(method = "tick", at = @At(value = "INVOKE", target = "Lnet/minecraft/item/ItemStack;getItem()Lnet/minecraft/item/Item;"), locals = LocalCapture.CAPTURE_FAILHARD, allow = 1) - private static void getStackRemainder(World world, BlockPos pos, BlockState state, AbstractFurnaceBlockEntity blockEntity, CallbackInfo ci, boolean bl, boolean bl2, ItemStack itemStack, ItemStack itemStack2, boolean bl3, boolean bl4, RecipeEntry recipeEntry, int i) { + private static void getStackRemainder(ServerWorld world, BlockPos pos, BlockState state, AbstractFurnaceBlockEntity blockEntity, CallbackInfo ci, boolean bl, boolean bl2, ItemStack itemStack, ItemStack itemStack2, boolean bl3, boolean bl4, RecipeEntry recipeEntry, SingleStackRecipeInput input, int i) { REMAINDER_STACK.set(itemStack.getRecipeRemainder()); } diff --git a/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/AnvilScreenHandlerMixin.java b/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/AnvilScreenHandlerMixin.java index 6436e6974b..dc7d361593 100644 --- a/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/AnvilScreenHandlerMixin.java +++ b/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/AnvilScreenHandlerMixin.java @@ -30,13 +30,14 @@ import net.minecraft.screen.ForgingScreenHandler; import net.minecraft.screen.ScreenHandlerContext; import net.minecraft.screen.ScreenHandlerType; +import net.minecraft.screen.slot.ForgingSlotsManager; import net.fabricmc.fabric.api.item.v1.EnchantingContext; @Mixin(AnvilScreenHandler.class) abstract class AnvilScreenHandlerMixin extends ForgingScreenHandler { - AnvilScreenHandlerMixin(@Nullable ScreenHandlerType type, int syncId, PlayerInventory playerInventory, ScreenHandlerContext context) { - super(type, syncId, playerInventory, context); + AnvilScreenHandlerMixin(@Nullable ScreenHandlerType type, int syncId, PlayerInventory playerInventory, ScreenHandlerContext context, ForgingSlotsManager forgingSlotsManager) { + super(type, syncId, playerInventory, context, forgingSlotsManager); } @Redirect( diff --git a/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/BrewingStandBlockEntityMixin.java b/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/BrewingStandBlockEntityMixin.java index 81a2e15d53..2517f175f1 100644 --- a/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/BrewingStandBlockEntityMixin.java +++ b/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/BrewingStandBlockEntityMixin.java @@ -16,8 +16,6 @@ package net.fabricmc.fabric.mixin.item; -import com.llamalad7.mixinextras.injector.wrapoperation.Operation; -import com.llamalad7.mixinextras.injector.wrapoperation.WrapOperation; import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.Unique; import org.spongepowered.asm.mixin.injection.At; @@ -28,7 +26,6 @@ import net.minecraft.block.entity.BrewingStandBlockEntity; import net.minecraft.item.Item; -import net.minecraft.item.ItemConvertible; import net.minecraft.item.ItemStack; import net.minecraft.util.collection.DefaultedList; import net.minecraft.util.math.BlockPos; @@ -44,16 +41,11 @@ private static void captureItemStack(World world, BlockPos pos, DefaultedList original) { + @Redirect(method = "craft", at = @At(value = "INVOKE", target = "Lnet/minecraft/item/Item;getRecipeRemainder()Lnet/minecraft/item/ItemStack;")) + private static ItemStack createStackRecipeRemainder(Item item) { ItemStack remainder = REMAINDER_STACK.get(); REMAINDER_STACK.remove(); return remainder; diff --git a/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/CraftingRecipeMixin.java b/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/CraftingRecipeMixin.java new file mode 100644 index 0000000000..fa6674aad3 --- /dev/null +++ b/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/CraftingRecipeMixin.java @@ -0,0 +1,45 @@ +/* + * Copyright (c) 2016, 2017, 2018, 2019 FabricMC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package net.fabricmc.fabric.mixin.item; + +import com.llamalad7.mixinextras.injector.wrapoperation.Operation; +import com.llamalad7.mixinextras.injector.wrapoperation.WrapOperation; +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Redirect; + +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.recipe.CraftingRecipe; + +import net.fabricmc.fabric.impl.item.RecipeRemainderHandler; + +@Mixin(CraftingRecipe.class) +public interface CraftingRecipeMixin { + @WrapOperation(method = "method_64671", at = @At(value = "INVOKE", target = "Lnet/minecraft/item/ItemStack;getItem()Lnet/minecraft/item/Item;")) + private static Item captureStack(ItemStack stack, Operation operation) { + RecipeRemainderHandler.REMAINDER_STACK.set(stack.getRecipeRemainder()); + return operation.call(stack); + } + + @Redirect(method = "method_64671", at = @At(value = "INVOKE", target = "Lnet/minecraft/item/Item;getRecipeRemainder()Lnet/minecraft/item/ItemStack;")) + private static ItemStack getStackRemainder(Item item) { + ItemStack remainder = RecipeRemainderHandler.REMAINDER_STACK.get(); + RecipeRemainderHandler.REMAINDER_STACK.remove(); + return remainder; + } +} diff --git a/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/RecipeMixin.java b/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/RecipeMixin.java deleted file mode 100644 index d2b9275fea..0000000000 --- a/fabric-item-api-v1/src/main/java/net/fabricmc/fabric/mixin/item/RecipeMixin.java +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Copyright (c) 2016, 2017, 2018, 2019 FabricMC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package net.fabricmc.fabric.mixin.item; - -import org.spongepowered.asm.mixin.Mixin; -import org.spongepowered.asm.mixin.injection.At; -import org.spongepowered.asm.mixin.injection.Inject; -import org.spongepowered.asm.mixin.injection.Redirect; -import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; -import org.spongepowered.asm.mixin.injection.callback.LocalCapture; - -import net.minecraft.item.Item; -import net.minecraft.item.ItemStack; -import net.minecraft.item.Items; -import net.minecraft.recipe.Recipe; -import net.minecraft.recipe.input.RecipeInput; -import net.minecraft.util.collection.DefaultedList; - -import net.fabricmc.fabric.impl.item.RecipeRemainderHandler; - -@Mixin(Recipe.class) -public interface RecipeMixin { - @Inject(method = "getRemainder", at = @At(value = "INVOKE", target = "Lnet/minecraft/recipe/input/RecipeInput;getStackInSlot(I)Lnet/minecraft/item/ItemStack;"), locals = LocalCapture.CAPTURE_FAILHARD) - default void captureStack(T inventory, CallbackInfoReturnable> cir, DefaultedList defaultedList, int i) { - RecipeRemainderHandler.REMAINDER_STACK.set(inventory.getStackInSlot(i).getRecipeRemainder()); - } - - @Redirect(method = "getRemainder", at = @At(value = "INVOKE", target = "Lnet/minecraft/item/Item;hasRecipeRemainder()Z")) - private boolean hasStackRemainder(Item instance) { - return !RecipeRemainderHandler.REMAINDER_STACK.get().isEmpty(); - } - - @Redirect(method = "getRemainder", at = @At(value = "INVOKE", target = "Lnet/minecraft/item/Item;getRecipeRemainder()Lnet/minecraft/item/Item;")) - private Item replaceGetRecipeRemainder(Item instance) { - return Items.AIR; - } - - @Redirect(method = "getRemainder", at = @At(value = "INVOKE", target = "Lnet/minecraft/util/collection/DefaultedList;set(ILjava/lang/Object;)Ljava/lang/Object;")) - private Object getStackRemainder(DefaultedList inventory, int index, Object element) { - Object remainder = inventory.set(index, RecipeRemainderHandler.REMAINDER_STACK.get()); - RecipeRemainderHandler.REMAINDER_STACK.remove(); - return remainder; - } -} diff --git a/fabric-item-api-v1/src/main/resources/fabric-item-api-v1.mixins.json b/fabric-item-api-v1/src/main/resources/fabric-item-api-v1.mixins.json index 72c8d11d02..a620f78d17 100644 --- a/fabric-item-api-v1/src/main/resources/fabric-item-api-v1.mixins.json +++ b/fabric-item-api-v1/src/main/resources/fabric-item-api-v1.mixins.json @@ -7,6 +7,7 @@ "AnvilScreenHandlerMixin", "BrewingStandBlockEntityMixin", "ComponentMapBuilderMixin", + "CraftingRecipeMixin", "EnchantmentBuilderAccessor", "EnchantCommandMixin", "EnchantmentHelperMixin", @@ -16,7 +17,6 @@ "ItemSettingsMixin", "ItemStackMixin", "LivingEntityMixin", - "RecipeMixin", "RegistriesMixin", "RegistryLoaderMixin" ], diff --git a/fabric-item-api-v1/src/testmod/java/net/fabricmc/fabric/test/item/gametest/RecipeGameTest.java b/fabric-item-api-v1/src/testmod/java/net/fabricmc/fabric/test/item/gametest/RecipeGameTest.java index 1a0283fe10..a37a73e4d5 100644 --- a/fabric-item-api-v1/src/testmod/java/net/fabricmc/fabric/test/item/gametest/RecipeGameTest.java +++ b/fabric-item-api-v1/src/testmod/java/net/fabricmc/fabric/test/item/gametest/RecipeGameTest.java @@ -20,17 +20,12 @@ import net.minecraft.item.ItemStack; import net.minecraft.item.Items; -import net.minecraft.recipe.IngredientPlacement; -import net.minecraft.recipe.Recipe; -import net.minecraft.recipe.RecipeSerializer; -import net.minecraft.recipe.RecipeType; +import net.minecraft.recipe.CraftingRecipe; import net.minecraft.recipe.input.CraftingRecipeInput; -import net.minecraft.registry.RegistryWrapper; import net.minecraft.test.GameTest; import net.minecraft.test.GameTestException; import net.minecraft.test.TestContext; import net.minecraft.util.collection.DefaultedList; -import net.minecraft.world.World; import net.fabricmc.fabric.api.gametest.v1.FabricGameTest; import net.fabricmc.fabric.test.item.CustomDamageTest; @@ -38,13 +33,11 @@ public class RecipeGameTest implements FabricGameTest { @GameTest(templateName = EMPTY_STRUCTURE) public void vanillaRemainderTest(TestContext context) { - Recipe testRecipe = createTestingRecipeInstance(); - CraftingRecipeInput inventory = CraftingRecipeInput.create(1, 2, List.of( new ItemStack(Items.WATER_BUCKET), new ItemStack(Items.DIAMOND))); - DefaultedList remainderList = testRecipe.getRemainder(inventory); + DefaultedList remainderList = CraftingRecipe.method_64671(inventory); assertStackList(remainderList, "Testing vanilla recipe remainder.", new ItemStack(Items.BUCKET), @@ -55,15 +48,13 @@ public void vanillaRemainderTest(TestContext context) { @GameTest(templateName = EMPTY_STRUCTURE) public void fabricRemainderTest(TestContext context) { - Recipe testRecipe = createTestingRecipeInstance(); - CraftingRecipeInput inventory = CraftingRecipeInput.create(1, 4, List.of( new ItemStack(CustomDamageTest.WEIRD_PICK), withDamage(new ItemStack(CustomDamageTest.WEIRD_PICK), 10), withDamage(new ItemStack(CustomDamageTest.WEIRD_PICK), 31), new ItemStack(Items.DIAMOND))); - DefaultedList remainderList = testRecipe.getRemainder(inventory); + DefaultedList remainderList = CraftingRecipe.method_64671(inventory); assertStackList(remainderList, "Testing fabric recipe remainder.", withDamage(new ItemStack(CustomDamageTest.WEIRD_PICK), 1), @@ -74,45 +65,6 @@ public void fabricRemainderTest(TestContext context) { context.complete(); } - private Recipe createTestingRecipeInstance() { - return new Recipe<>() { - @Override - public boolean matches(CraftingRecipeInput recipeInput, World world) { - return true; - } - - @Override - public ItemStack craft(CraftingRecipeInput recipeInput, RegistryWrapper.WrapperLookup wrapperLookup) { - return null; - } - - @Override - public boolean fits(int width, int height) { - return true; - } - - @Override - public ItemStack getResult(RegistryWrapper.WrapperLookup wrapperLookup) { - return null; - } - - @Override - public RecipeSerializer getSerializer() { - return null; - } - - @Override - public RecipeType getType() { - return null; - } - - @Override - public IngredientPlacement getIngredientPlacement() { - return IngredientPlacement.NONE; - } - }; - } - private void assertStackList(DefaultedList stackList, String extraErrorInfo, ItemStack... stacks) { for (int i = 0; i < stackList.size(); i++) { ItemStack currentStack = stackList.get(i); diff --git a/fabric-lifecycle-events-v1/src/main/java/net/fabricmc/fabric/mixin/event/lifecycle/PlayerManagerMixin.java b/fabric-lifecycle-events-v1/src/main/java/net/fabricmc/fabric/mixin/event/lifecycle/PlayerManagerMixin.java index 8f65afc4cc..a4c7766ea3 100644 --- a/fabric-lifecycle-events-v1/src/main/java/net/fabricmc/fabric/mixin/event/lifecycle/PlayerManagerMixin.java +++ b/fabric-lifecycle-events-v1/src/main/java/net/fabricmc/fabric/mixin/event/lifecycle/PlayerManagerMixin.java @@ -32,7 +32,7 @@ public class PlayerManagerMixin { @Inject( method = "onPlayerConnect", - at = @At(value = "INVOKE", target = "net/minecraft/network/packet/s2c/play/SynchronizeRecipesS2CPacket.(Ljava/util/Collection;)V") + at = @At(value = "NEW", target = "net/minecraft/network/packet/s2c/play/SynchronizeRecipesS2CPacket") ) private void hookOnPlayerConnect(ClientConnection connection, ServerPlayerEntity player, ConnectedClientData arg, CallbackInfo ci) { ServerLifecycleEvents.SYNC_DATA_PACK_CONTENTS.invoker().onSyncDataPackContents(player, true); diff --git a/fabric-loot-api-v3/src/testmod/java/net/fabricmc/fabric/test/loot/LootTest.java b/fabric-loot-api-v3/src/testmod/java/net/fabricmc/fabric/test/loot/LootTest.java index cb7dfb9d56..6bf806d287 100644 --- a/fabric-loot-api-v3/src/testmod/java/net/fabricmc/fabric/test/loot/LootTest.java +++ b/fabric-loot-api-v3/src/testmod/java/net/fabricmc/fabric/test/loot/LootTest.java @@ -103,7 +103,7 @@ public void onInitialize() { }); LootTableEvents.MODIFY.register((key, tableBuilder, source, registries) -> { - if (EntityType.SALMON.getLootTable().orElse(null) == key) { + if (EntityType.SALMON.getLootTableKey().orElse(null) == key) { Optional> lure = registries.getOptional(RegistryKeys.ENCHANTMENT).flatMap(registry -> registry.getOptional(Enchantments.LURE)); lure.ifPresent((lureEnchantment) -> tableBuilder.pool(LootPool.builder().with( diff --git a/fabric-recipe-api-v1/src/testmod/java/net/fabricmc/fabric/test/recipe/ingredient/ShapelessRecipeMatchTests.java b/fabric-recipe-api-v1/src/testmod/java/net/fabricmc/fabric/test/recipe/ingredient/ShapelessRecipeMatchTests.java index 9832a6794d..aad276039b 100644 --- a/fabric-recipe-api-v1/src/testmod/java/net/fabricmc/fabric/test/recipe/ingredient/ShapelessRecipeMatchTests.java +++ b/fabric-recipe-api-v1/src/testmod/java/net/fabricmc/fabric/test/recipe/ingredient/ShapelessRecipeMatchTests.java @@ -22,8 +22,11 @@ import net.minecraft.item.ItemStack; import net.minecraft.item.Items; +import net.minecraft.recipe.Recipe; import net.minecraft.recipe.ShapelessRecipe; import net.minecraft.recipe.input.CraftingRecipeInput; +import net.minecraft.registry.RegistryKey; +import net.minecraft.registry.RegistryKeys; import net.minecraft.test.GameTest; import net.minecraft.test.GameTestException; import net.minecraft.test.TestContext; @@ -37,8 +40,8 @@ public class ShapelessRecipeMatchTests { */ @GameTest(templateName = FabricGameTest.EMPTY_STRUCTURE) public void testShapelessMatch(TestContext context) { - Identifier recipeId = Identifier.of("fabric-recipe-api-v1-testmod", "test_shapeless_match"); - ShapelessRecipe recipe = (ShapelessRecipe) context.getWorld().getRecipeManager().get(recipeId).get().value(); + RegistryKey> recipeKey = RegistryKey.of(RegistryKeys.RECIPE, Identifier.of("fabric-recipe-api-v1-testmod", "test_shapeless_match")); + ShapelessRecipe recipe = (ShapelessRecipe) context.getWorld().getRecipeManager().get(recipeKey).get().value(); ItemStack undamagedPickaxe = new ItemStack(Items.DIAMOND_PICKAXE); ItemStack damagedPickaxe = new ItemStack(Items.DIAMOND_PICKAXE); diff --git a/fabric-registry-sync-v0/src/main/java/net/fabricmc/fabric/impl/registry/sync/FabricRegistryInit.java b/fabric-registry-sync-v0/src/main/java/net/fabricmc/fabric/impl/registry/sync/FabricRegistryInit.java index dcfaef4577..249b8cc87d 100644 --- a/fabric-registry-sync-v0/src/main/java/net/fabricmc/fabric/impl/registry/sync/FabricRegistryInit.java +++ b/fabric-registry-sync-v0/src/main/java/net/fabricmc/fabric/impl/registry/sync/FabricRegistryInit.java @@ -207,5 +207,13 @@ public void onInitialize() { // Synced via PacketCodecs.registry RegistryAttributeHolder.get(Registries.CONSUME_EFFECT_TYPE) .addAttribute(RegistryAttribute.SYNCED); + + // Synced via PacketCodecs.registryValue + RegistryAttributeHolder.get(Registries.RECIPE_DISPLAY) + .addAttribute(RegistryAttribute.SYNCED); + + // Synced via PacketCodecs.registryValue + RegistryAttributeHolder.get(Registries.SLOT_DISPLAY) + .addAttribute(RegistryAttribute.SYNCED); } } diff --git a/fabric-rendering-v1/src/client/java/net/fabricmc/fabric/mixin/client/rendering/WorldRendererMixin.java b/fabric-rendering-v1/src/client/java/net/fabricmc/fabric/mixin/client/rendering/WorldRendererMixin.java index 732d8ecba3..e52413d096 100644 --- a/fabric-rendering-v1/src/client/java/net/fabricmc/fabric/mixin/client/rendering/WorldRendererMixin.java +++ b/fabric-rendering-v1/src/client/java/net/fabricmc/fabric/mixin/client/rendering/WorldRendererMixin.java @@ -116,7 +116,7 @@ private void beforeRenderOutline(CallbackInfo ci) { @SuppressWarnings("ConstantConditions") @Inject(method = "drawBlockOutline", at = @At("HEAD"), cancellable = true) - private void onDrawBlockOutline(MatrixStack matrixStack, VertexConsumer vertexConsumer, Entity entity, double cameraX, double cameraY, double cameraZ, BlockPos blockPos, BlockState blockState, CallbackInfo ci) { + private void onDrawBlockOutline(MatrixStack matrixStack, VertexConsumer vertexConsumer, Entity entity, double cameraX, double cameraY, double cameraZ, BlockPos blockPos, BlockState blockState, int color, CallbackInfo ci) { if (!context.renderBlockOutline) { // Was cancelled before we got here, so do not // fire the BLOCK_OUTLINE event per contract of the API. diff --git a/fabric-resource-conditions-api-v1/src/testmod/java/net/fabricmc/fabric/test/resource/conditions/ConditionalResourcesTest.java b/fabric-resource-conditions-api-v1/src/testmod/java/net/fabricmc/fabric/test/resource/conditions/ConditionalResourcesTest.java index 5acd63330b..1f90a727b3 100644 --- a/fabric-resource-conditions-api-v1/src/testmod/java/net/fabricmc/fabric/test/resource/conditions/ConditionalResourcesTest.java +++ b/fabric-resource-conditions-api-v1/src/testmod/java/net/fabricmc/fabric/test/resource/conditions/ConditionalResourcesTest.java @@ -41,35 +41,35 @@ private static Identifier id(String path) { public void conditionalRecipes(TestContext context) { RecipeManager manager = context.getWorld().getRecipeManager(); - if (manager.get(id("not_loaded")).isPresent()) { + if (manager.get(RegistryKey.of(RegistryKeys.RECIPE, id("not_loaded"))).isPresent()) { throw new AssertionError("not_loaded recipe should not have been loaded."); } - if (manager.get(id("loaded")).isEmpty()) { + if (manager.get(RegistryKey.of(RegistryKeys.RECIPE, id("loaded"))).isEmpty()) { throw new AssertionError("loaded recipe should have been loaded."); } - if (manager.get(id("item_tags_populated")).isEmpty()) { + if (manager.get(RegistryKey.of(RegistryKeys.RECIPE, id("item_tags_populated"))).isEmpty()) { throw new AssertionError("item_tags_populated recipe should have been loaded."); } - if (manager.get(id("tags_populated")).isEmpty()) { + if (manager.get(RegistryKey.of(RegistryKeys.RECIPE, id("tags_populated"))).isEmpty()) { throw new AssertionError("tags_populated recipe should have been loaded."); } - if (manager.get(id("tags_populated_default")).isEmpty()) { + if (manager.get(RegistryKey.of(RegistryKeys.RECIPE, id("tags_populated_default"))).isEmpty()) { throw new AssertionError("tags_populated_default recipe should have been loaded."); } - if (manager.get(id("tags_not_populated")).isPresent()) { + if (manager.get(RegistryKey.of(RegistryKeys.RECIPE, id("tags_not_populated"))).isPresent()) { throw new AssertionError("tags_not_populated recipe should not have been loaded."); } - if (manager.get(id("features_enabled")).isEmpty()) { + if (manager.get(RegistryKey.of(RegistryKeys.RECIPE, id("features_enabled"))).isEmpty()) { throw new AssertionError("features_enabled recipe should have been loaded."); } - long loadedRecipes = manager.values().stream().filter(r -> r.id().getNamespace().equals(MOD_ID)).count(); + long loadedRecipes = manager.values().stream().filter(r -> r.id().getValue().getNamespace().equals(MOD_ID)).count(); if (loadedRecipes != 5) throw new AssertionError("Unexpected loaded recipe count: " + loadedRecipes); context.complete(); diff --git a/fabric-transfer-api-v1/src/main/java/net/fabricmc/fabric/mixin/transfer/AbstractFurnaceBlockEntityMixin.java b/fabric-transfer-api-v1/src/main/java/net/fabricmc/fabric/mixin/transfer/AbstractFurnaceBlockEntityMixin.java index 51c21050b6..03c301c673 100644 --- a/fabric-transfer-api-v1/src/main/java/net/fabricmc/fabric/mixin/transfer/AbstractFurnaceBlockEntityMixin.java +++ b/fabric-transfer-api-v1/src/main/java/net/fabricmc/fabric/mixin/transfer/AbstractFurnaceBlockEntityMixin.java @@ -28,9 +28,9 @@ import net.minecraft.block.entity.BlockEntityType; import net.minecraft.block.entity.LockableContainerBlockEntity; import net.minecraft.item.ItemStack; +import net.minecraft.server.world.ServerWorld; import net.minecraft.util.collection.DefaultedList; import net.minecraft.util.math.BlockPos; -import net.minecraft.world.World; import net.fabricmc.fabric.impl.transfer.item.SpecialLogicInventory; @@ -75,15 +75,15 @@ public void fabric_onFinalCommit(int slot, ItemStack oldStack, ItemStack newStac // Update cook time if needed. Code taken from AbstractFurnaceBlockEntity#setStack. boolean bl = !stack.isEmpty() && ItemStack.areItemsAndComponentsEqual(stack, itemStack); - if (!bl) { - this.cookTimeTotal = getCookTime(this.world, (AbstractFurnaceBlockEntity) (Object) this); + if (!bl && this.world instanceof ServerWorld world) { + this.cookTimeTotal = getCookTime(world, (AbstractFurnaceBlockEntity) (Object) this); this.cookTime = 0; } } } @Shadow - private static int getCookTime(World world, AbstractFurnaceBlockEntity abstractFurnaceBlockEntity) { + private static int getCookTime(ServerWorld world, AbstractFurnaceBlockEntity abstractFurnaceBlockEntity) { throw new AssertionError(); } } diff --git a/gradle.properties b/gradle.properties index eae18ecee7..8dc0d32a6e 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,9 +2,9 @@ org.gradle.jvmargs=-Xmx2560M org.gradle.parallel=true fabric.loom.multiProjectOptimisation=true -version=0.105.1 -minecraft_version=24w39a -yarn_version=+build.4 +version=0.105.2 +minecraft_version=24w40a +yarn_version=+build.3 loader_version=0.16.4 installer_version=1.0.1 @@ -13,7 +13,7 @@ curseforge_minecraft_version=1.21.2-Snapshot # Do not manually update, use the bumpversions task: fabric-api-base-version=0.4.46 -fabric-api-lookup-api-v1-version=1.6.75 +fabric-api-lookup-api-v1-version=1.6.76 fabric-biome-api-v1-version=14.0.3 fabric-block-api-v1-version=1.0.26 fabric-block-view-api-v2-version=1.0.14 @@ -21,42 +21,42 @@ fabric-blockrenderlayer-v1-version=2.0.0 fabric-command-api-v1-version=1.2.54 fabric-command-api-v2-version=2.2.33 fabric-commands-v0-version=0.2.71 -fabric-content-registries-v0-version=9.1.1 +fabric-content-registries-v0-version=9.1.2 fabric-crash-report-info-v1-version=0.3.1 fabric-data-attachment-api-v1-version=1.1.35 -fabric-data-generation-api-v1-version=21.0.9 -fabric-dimensions-v1-version=4.0.4 +fabric-data-generation-api-v1-version=21.0.10 +fabric-dimensions-v1-version=4.0.5 fabric-entity-events-v1-version=2.0.3 fabric-events-interaction-v0-version=2.0.6 fabric-game-rule-api-v1-version=1.0.57 fabric-gametest-api-v1-version=2.0.10 -fabric-item-api-v1-version=11.1.1 +fabric-item-api-v1-version=11.1.2 fabric-item-group-api-v1-version=4.1.11 fabric-key-binding-api-v1-version=1.0.51 fabric-keybindings-v0-version=0.2.49 -fabric-lifecycle-events-v1-version=2.3.19 -fabric-loot-api-v2-version=3.0.20 -fabric-loot-api-v3-version=1.0.8 +fabric-lifecycle-events-v1-version=2.3.20 +fabric-loot-api-v2-version=3.0.21 +fabric-loot-api-v3-version=1.0.9 fabric-message-api-v1-version=6.0.17 fabric-model-loading-api-v1-version=3.0.5 fabric-networking-api-v1-version=4.3.0 fabric-object-builder-api-v1-version=17.0.4 fabric-particles-v1-version=4.0.6 -fabric-recipe-api-v1-version=6.0.5 -fabric-registry-sync-v0-version=5.1.9 +fabric-recipe-api-v1-version=6.0.6 +fabric-registry-sync-v0-version=5.1.10 fabric-renderer-api-v1-version=4.0.0 fabric-renderer-indigo-version=1.9.0 fabric-rendering-data-attachment-v1-version=0.3.52 fabric-rendering-fluids-v1-version=3.1.11 -fabric-rendering-v0-version=1.1.77 -fabric-rendering-v1-version=8.0.1 -fabric-resource-conditions-api-v1-version=5.0.4 +fabric-rendering-v0-version=1.1.78 +fabric-rendering-v1-version=8.0.2 +fabric-resource-conditions-api-v1-version=5.0.5 fabric-resource-loader-v0-version=3.0.2 fabric-screen-api-v1-version=2.0.29 -fabric-screen-handler-api-v1-version=1.3.93 +fabric-screen-handler-api-v1-version=1.3.94 fabric-sound-api-v1-version=1.0.27 -fabric-transfer-api-v1-version=5.3.1 +fabric-transfer-api-v1-version=5.3.2 fabric-transitive-access-wideners-v1-version=6.1.5 -fabric-convention-tags-v1-version=2.0.30 -fabric-convention-tags-v2-version=2.8.1 -fabric-client-tags-api-v1-version=1.1.19 +fabric-convention-tags-v1-version=2.0.31 +fabric-convention-tags-v2-version=2.8.2 +fabric-client-tags-api-v1-version=1.1.20