I need help with double jump mechanic

Started by 404NNF on

Topic category: Help with modding (Java Edition)

Last seen on 20:59, 2. Jul 2023
Joined May 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I need help with double jump mechanic

Im trying to make a double jump enchant called "Grace" it all works perfectly except I can't figure out how to make it so that It can only be used once in the air. Currently im using a logic/booleen variable called "Canjump", it requires the player for "Canjump" to be true for the effect to activate, after the effect activates it sets "Canjump" to false, then, when hitting the ground "Canjump" is set to true once again. For some reason this isn't working. I will provide a picture, thanks in advanced!

 

 

 

 

Last seen on 20:59, 2. Jul 2023
Joined May 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
The image didn't work so I…
Tue, 05/23/2023 - 19:30

The image didn't work so I will just send the link https://ibb.co/dDPCBpS. Sorry about that.

Last seen on 17:00, 1. Jun 2023
Joined Sep 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Hello! This is my first…
Thu, 05/25/2023 - 16:58

Hello! This is my first tutorial, so let me get into it!

1. Make a new keybind - Bind it to whatever you want and name it whatever you want

2. In the triggers for the keybind, make a procedure on key pressed

3. In the procedure put this -->

You can change the "vy" to how high you want to go. I found that 0.5 is about 1 block. You can change the "vx" to how far you want to go when using the double jump ability!
And with that, thats all you need to do! If you want to use make this an enchant:
1. Make a enchant - name whatever
2. In the keybind procedure (see above) check if your armor piece has your enchant then ovveride the motion vector then thats it!
Hope you enjoyed!!!