I am trying to make a mod and I am making custom weapon. I have most of it done and I need a few more things. The main thing I need is the code for making my item --with the id of 5000-- have durability and a visible durability bar. If anyone knows how to do this can you type up the code for it.
I dont see anything wrong with it. try making the dmg interger even more.
Rollback Post to RevisionRollBack
Heard of an app called AppNana? It's an app that rewards you for installing games, testing apps, watching adds, with Google Play, Amazon, and iTunes gift cards, and more! And the app, is completely free!
An easy way of earning Nanas is to add other people's Invite Codes. Whenever you invite someone or get invited, you get 2.5k nanas!
My code is t3305123, pm me your codes so we can just keep gettin nanas for doing pretty much nothing at all!
Block.setDestroyTime(Id, time); //set the destroy time if the Player holds the Item, use this method for all blocks you want another time, for example stone and all ores
Block.setDestroyTime(Id, time); //reeset the destroy time if the Player don´t holds the Item, you can see all destroy times in the Minecraft Wiki