DoubleJump Plugin


#1

Hey!

I just need a (hopefully) simple plugin that allows players to Double Jump by double clicking the space bar, sending them forward in the direction they're looking.

There are a few small (optional) things that would be great if you could implement, but not necessary, and you could send me a simpler build first before going into this stuff:

  • Disable Double-Jumping when /fly is enabled
  • Have some kind of command to toggle double jump (eg. /doublejump)
  • Have some kind of permission for this toggle (eg. doublejump.toggle)

#2

I may be wrong, but I don't think it's possible to tell if a player hits the space bar again after they're already in the air, since Minecraft doesn't allow jumping while airborne.


#3

Hm really?
I've seen many similar plugins done with Bukkit from 1.7.10 up to 1.9, so I'm sure it's possible somehow.


#4

I've only ever seen Bukkit plugins that did it with a double sneak/shift, but you could be right.


#5

This is in fact incredibly easy. You allow fly, and when the player starts flying, you update their velocity and remove their ability to fly until they touch the ground again. It's a little bit janky, but it 100% works.


#6

http://dev.bukkit.org/bukkit-plugins/double-jump-plugin/ is a popular one that simply uses the double space bar.

Good to hear! I have no idea how to do this (or any plugin developing) unfortunately, any chance you (or of course anyone else) could quickly draw a plugin up for me?


#7

I've tried before, but Sponge presents entity velocities in a different way than bukkit (not sure how different), so I'm not sure the math you'd need to use.


#8

Just your friendly neighborhood bump!


#9

You could say this is a double bump.
:smiley:


#10

I admire you sir xD

But really, anyone who can find a way to make this work?


#11

I've already made this before in Bukkit, it's extremely easy. I'll see if I can quickly whip it up in Sponge.


#12

Awesome, thanks!
Get back to me on how it's working :smiley:


#13

I finished it, I tested it and it works.

Things you can change in the config:
- If a permission is required to use doublejump (If true, then perm is doublejump.use)
- Vertical boost power
- Horizontal boost power
- Whether a sound will play when they boost

Download: Link

If for some reason there are any problems just let me know.


#14

This plugins great, actually incredibly well done, thank you so much -
My players have been requesting one small thing that I was wondering if possible: Can you change the vertical/horizontal ratio depending on where a player is looking when they double jump? For example, looking up would give me a lot of vertical and not much horizontal, and reverse for looking straight.


#15

One more small issue -
If a player has /fly, they can't seem to use it due to double jump. Any fixes?


#16

Enable the option in the config that a permission is required to use it, and don't give the players the permission.


#17

Do you release that plugin in the plugins forum section?


#18

No, I just made it for the person here. And if I were to release it I would use Ore, not the forums.


#19

Hm, okay, that's of course your decision. I only thought that you could share your work in a more public way.
I didn't mentioned Ore because it's beta and it could be reset at every moment.


#20

Yeah, but like I said I didn't share it because it was just a request from the OP.
I don't know if this is something that everyone would use/need.