Posted August 9, 201510 yr Hey, I have an item which has 2 timers stored in NBT, a cooldown and a time remaining counter. For some reason, if the NBT is being modified, the item does some crazy jumping thing if you hold it in your hand (Like when you right click an item on the ground, except constant). I don't remember this being an issue in 1.7. Here is my code: http://pastebin.com/C9ZrfKVY Any help would be much appreciated!
August 9, 201510 yr Do you need to handle the cooldown in that manner? One alternative would be to store its last use time ( World#getTotalWorldTime ) in the NBT and just compare that to the current time when the player tries to use it. I do something like this here. If you have to handle the cooldown like this, override Item#shouldCauseReequipAnimation to ignore the NBT of the stacks. Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.