If you have already accidentally broken a valuable item with rare enchantments once, then you need the SaveTools mod. It allows you to preserve such items without making significant changes to the mechanics of the game. Thanks to this feature, it can be used without any problems both in a single player game and on any server. When a weapon or tool reaches a critical point (you can set it in the settings), they will simply move to your inventory and you can repair them.
How to install SaveTools mod
- Make sure you have installed Minecraft Forge.
- Download Cloth Config API Library.
- Download the mod for your version of the game.
- Put it in the ‘mods’ folder, which is located in the game folder.