Started by
BIGOOF
on
Topic category: Help with Minecraft modding (Java Edition)
Hi, I'm working on a mod that adds some enchantments, including one that grants the player the ability to double jump. The problem is that I can't find a way to limit the amount of jumps. I've tried using local variables, but it doesn't seem to have any effect. Might there be a problem with the variables, or do you know a different solution?
It looks like the image isn't loading. Here it is: https://imgur.com/a/HTTJVw7
Why did you make a variable? It's useless, you just have to check if certain item has that enchantment. And you have done it that every time you fall you will, supposedly, jump. And the part of the sound just doesn't make sense to me, because it will play the sound eery tick. I think that you need to make it on player's tick update, but try to think about what I've written here. If that¡s not the problem i don't know hao to fix it.
every*
Local variables reset every time the procedure is called. You will have to make an NBT variable for this to work properly.
thanks!