Topic category: User side tutorials
MCreator 1.8.2 just recently released and already I am taking advantage of being able to use one of the program's newest features -- The item damage blocks.
"Get max possible damage of the provided item" and "Get damage of the provided item" are pretty self-explanatory. "Get max possible damage of the provided item" states if an item's damage has reached or surpassed the coded durability limit. "Get damage of the provided item" looks for the current damage on an item.
Now, during normal gameplay, these aren't needed, as the game automatically knows, given the coded limit, when to have an item break, like how Gold tools break in 32 uses, and Diamond, at 1,562.
However, what happens when you have an effect with a tool and, when activated, uses durability? That's where these come into play, as custom effects do not apply to the coded durability limit, allowing tools to go way into the negatives. Those of you who are familiar with my mod, DovahCraft, you may have seen something like this being done on most of my Pickaxes. Thanks to these two blocks, those errors can now be corrected. Here's an example, and a run-down on what's going on, and how it works:
The above picture is of my Obsidium Pickaxe's procedure. This can be used as a reference if need to.
Now, what's going on here?
When Right-Clicked in the air, the game looks for an Obsidium Pickaxe in the main hand. If true, then it applies a Resistance potion effect for 300 ticks, or 15 seconds, with level 2 (Resistance 3, as level 0 registers as 1, level 1 is 2, etc.). It will also deal damage of 100 durability, play a sound effect, and print a message. Now, given MCreator 1.8.2's newest update, the item will now break if the effect is used too much, i.e. using up all durability points.
This post is mostly for reference to those who haven't yet used the new procedure blocks or haven't updated to 1.8.2 yet. If this helped at all, then awesome!
Nice tutorial :)
Thanks! This is one of the biggest changes I was looking forward to for 1.8.2, among some others.
Glad to hear you found some useful new features :)
how to do a sword that do 50% of the enemy's max health