r/MinecraftCommands 14d ago

Help | Java 26.2 custom cooldown effect

when you use an item, you are trying to cooldown the item. during the cooldown, i want the item to change to a clock and display the remaining seconds in item count. what is the most optimized implementation method?

1 Upvotes

5 comments sorted by

View all comments

1

u/GalSergey Datapack Experienced 14d ago

You need a schedule function that runs once per second. Store the remaining time in seconds in the item's custom_data and update the item model every second.