Curios API (Forge/NeoForge)

Curios API (Forge/NeoForge)

140M Downloads

[Feature]: Replace command improvement

Paulino0o opened this issue ยท 0 comments

commented

What is the new feature or improvement?

Hi there,

I am trying to make a game using mods and datapacks and one key part is equipping and unequipping a toolbelt from the toolbelt mod using commands. For unequipping i just remove the belt slot and add it back, and the toolbelt goes to the player inventory.

On the other hand I can't seem to find a way to equip it back. I wanted to use the "/curios replace" command but that only works by replacing WITH a said item. Since the toolbelt has attached nbt data (weapons, durabilities, etc) I can't get that data to replace it on the player belt slot.

My suggestion is adding an option just like with the command (for exemple) "/item replace entity @s hotbar.0 from entity @s hotbar.1". This exemple replaces the item in hotbar.0 with the item in hotbar.1 (nbt included).

It could be something like "/curios replace belt 0 @s from entity @s hotbar.0" (for exemple). This would coppy the item in hotbar.0 to the belt slot, inlcuding all the nbt.