Hello, I would like to know how to add a "stamina" function to Minecraft, if there even is a way. What I would like is to make the player gain mining fatigue 50 after mining a certain number of blocks. How can I do this?
There is a scoreboard objective that deals with players running it was like “stat.sprintcm” something like that.
You can try with a stat.mineBlock scoreboard objective.
Wouldn’t the mineBlock only determines one type of block being mined?
I am not sure. There is "stat.drop" and it works if a player drops any item. The wiki says that you can specify the id of the dropped item. I think it might be the same with "stat.mineBlock".
True, you'll have to create 195 objectives for all minable blocks and add them all up in a single objective with operations.
I create mods for Vanilla Minecraft.
Check out my YT channel: TheCommandFreak
I wonder if just using "stat.mineBlock" would work. If it does, all these "195 objectives for all minable blocks" won't be needed.
I needed this for my thirst system as well, so I tested it. Does not work, requires subcriteria.