Started by
Evil_Soul
on
Topic category: Advanced modding
HeY!
So I created a pickaxe that you have to load with coals. Like that:
but I want to give a pickaxe that have only 8 durability.
how do I do that? Is it possible?
Edited by Evil_Soul on Fri, 01/29/2021 - 14:16
I guess the pickaxe you get from "loading" it is a separate item, so you can simply set the durability of that item to 8 I think.
Which damage modifier should I use, because none of them work for me.
That won't work as you are applying the damage to any pickaxe not the one in your inventory.
Make an local itemstack variable as the pickaxe. Apply the damage to the itemstack. Then add to your inventory.
How do I do that?
I'm not a genius of itemstack.
It's just a variable you can create.
Look here for details on creating one. https://mcreator.net/wiki/variables
Yeah I know, but I don't know how to do it. One of my procedures is working:
but the other is not:
what should I do?
In the second image, Replace provided itemstack to the torch pickaxe. Then add the get local pickaxe to your inventory.
Thanks for the help, I make this and it works perfectly.