As you might know, starting with Minecraft 1.8, the repair cost for an item goes up the more it was previously repaired, to the point where the item can no longer be repaired.

Is there a way to revert this change using command blocks?


The repair cost of an item is saved in the items NBT data, specifically the RepairCost tag. Knowing this, we can easily create a command block contraption that resets this tag.

Simple version:

Create a redstone clock inside your spawn-chunks (I suggest placing it inside a bedrock box), and use it to power a command block with the following command:

/entitydata @e[type=Item] {tag:{RepairCost:0}}

This will add the RepairCost tag to every item that is lying on the ground, including those who never had it, or for which it makes no sense, such as Cobblestone or Logs. I can't think of a better, non-tedious method, however.

  • 1
    Nice self answer. – Tim May 22 '15 at 16:25
  • @Tim thanks for linking this from the other question. That question was the one that prompted this question and answer, but I forgot to link it myself. – MrLemon May 22 '15 at 22:32
  • You know that this wont work right, the @a will only select all players and cannot select any items. Instead you must use @e. – ModDL May 23 '15 at 4:54
  • @MrLemon I guessed that's what you wanted :) – Tim May 23 '15 at 8:48
  • @ModDL you are right of course. Now I wonder how I overlooked your comment 7 months ago... – MrLemon Jan 4 '16 at 13:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.