Jump to content

[1.8.9] Continuous jump animation


Zethariel

Recommended Posts

Hello!

 

I am trying to play a continuous jump animation if the player is constantly jumping (space held down). The issue I am having is that I can't seem to find a way to check if the entity has a jump queued up (this is a client side mod only, so I need a reliable way for entities to be able to tell the renderer that it should keep rendering the jump animation despite having hit the ground).

 

Currently I am playing the fly animation only when !onGround, which produces a hiccup the moment onGround becomes true for the couple of frames it takes the entity to land and resume a jump.

 

Is there a magic method or property I'm missing? Maybe I should be looking in the player classes direct?

 

Thanks!

 

 

EDIT: found an isJumping property in the Entity class, but of course why would it have a getter...? Sometimes the choices made in Minecraft are appaling. What do now?

I do pony stuff :3

Link to comment
Share on other sites

You could use an access transformer to gain access to the field.

 

If you mean Reflection, that'd be slow and I can't be bothered to figure out what the obfuscated field would be named. Decided to not bother with this as the mod I'm basing mine off of didn't manage to solve the problem either.

 

This thread can be, idk, just forgotten I guess :P

I do pony stuff :3

Link to comment
Share on other sites

I can't be bothered to figure out what the obfuscated field would be named.

 

It's in a god damn CSV file, its super easy to open that up in Excel and hit Ctrl-F.

The hard part is remembering where that CSV file is located.

 

C:\Users\[username]\.gradle\caches\minecraft\de\oceanlabs\mcp\mcp_snapshot\[snapshot num]\fields.csv

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.