#Output item with modified NBT for smithing recipe

5 messages · Page 1 of 1 (latest)

limpid geyser
#

Im trying to make a script for my modpack that would make it so when an input item has a certain name EX: Ancient Iron Sword, it can be smithed into a differently named upgraded item EX Restored Diamond Sword. my current script looks like this
ServerEvents.recipes(event => { event.smithing( Item.of('minecraft:diamond_sword', "{display:{Name:'{\"text\":\"Restored Diamond Sword\"}'}}").strongNBT(), 'minecraft:sculk_vein', Item.of('minecraft:iron_sword', "{display:{Name:'{\"text\":\"Ancient Iron Sword\"}'}}").weakNBT(), 'minecraft:diamond_block' ) })

Ive tested this so far and it seems like the input item NBT works, but the Diamond sword being output always has the same name as the Iron sword going in, rather than what is specified here.
Screenshot is of the in game results (iron sword looks funny because this whole thing is for CIT shenanigans)

modern axleBOT
#

Once your ticket has been resolved, please close it with </ticket close:1054771505520717835> command!

limpid geyser
#

Output item with modified NBT for smithing recipe

radiant goblet
#

I don't think .modifyResult() works properly with smithing recipes or this would be possible.
I tried doing a custom smithing recipe for Sophisticated Backpacks and couldn't preserve all NBT data from the input item in the same way I can with a crafting recipe.

limpid geyser
#

thats quite unfortunate. Yeah ive been looking around the server and tinkering with all sorts of things and havent managed to get anything working.