mojira.dev
MC-269268

components don't work on the smithing table

When you try to make the result of the recipe type "minecraft:smithing_transform" use components, the recipe works, but not the components

How to reproduce

  1. Download the attached data pack, which adds a smithing transform recipe

  2. Try crafting the custom recipe in a smithing table with the 3 slots filled with stone

  3. ❌ Notice that the resulting stone does not have the custom lore component

Attachments

Comments 4

Please provide the datapack used when experiecing this issue

Can confirm. The issue is in SmithingTransformRecipe#assemble, where it doesn't incorporating/patch the result components.

public ItemStack assemble(Container container, RegistryAccess registries) {
    return container.getItem(1).transmuteCopy(this.result.getItem(), this.result.getCount());
}

This would be expected because the 24w10a article states:

Recipe types [...] and smithing_transform now accept components for the result item stack

Can confirm. Also still present in 24w11a
I thought I was going insane, but I'm glad to see the bug reported

Gonzamayo

slicedlime

Confirmed

Platform

Important

Crafting

command, component, datapack, nbt, nbt-component, recipe, smithing_table

24w10a, 24w11a

24w12a

Retrieved