How to make character less floaty

I wanted to preface this by saying I am really liking the physics library! Very easy to use.

When my character is jumping, he seems to float in the air, it doesn’t seem to have any weight to it. If I increase the values too much, I get a lot of jittery behavior.

I also noticed, when he is going near an edge, he kind of gets lowered a little before falling off. This is because the capsule is a sphere at the bottom. Is there any way to avoid this behavior?

Here is the relevant code:


CapsuleCollisionShape capsule = new CapsuleCollisionShape(1.75f, 6f);

physControl = new CharacterControl(capsule, .5f);






You could try making stronger gravity, but that does cause some jittery if you put it too high.

Try resizing the character instead. If your character is bigger the leap will seam much smaller.

Also as for the capsulecollision is it not a very good interactive way of knowing that your on the edge?

If you really want to get rid of it then you can take any mesh and turn it into a collisionshape:

[java]CollisionShape sceneShape =

CollisionShapeFactory.createMeshShape((Node) mesh);[/java]

thatway you can make a square or cylinder instead of a capsule which would solve your edge problem.

Do you know a good size? I’m using Oto at the size he is. If I increase his size, i’ll have to increase the map size.

Right now one tile is 8x8. I’m not sure if things get weird at certain sizes or not.

Thank you for the help so far.

Ahh ok. You shouldn’t resize oto, I think it’s an ok size.

The “tiles” that you mention might be too big, maybe go with half their size and then ur able to drag up the gravity without the same effect…