Hi all,
I try to put some gravity in my game. But I have a problem.
I want a normal gravity of a Vector3f(0, -2, 0). But the player gravity must be set to Vector3f(0, -10, 0).
First, I set the gravity from the state :
[java]bulletAppState.getPhysicsSpace().setGravity(new Vector3f(0, -2, 0));[/java]
And after, I create the control and link it with the bulletAppState
[java]playerControl = new BetterCharacterControl(1.5f, 4, 30f);
playerControl.setJumpForce(new Vector3f(0, 300, 0));
playerControl.setGravity(new Vector3f(0, -10, 0));
playerNode.addControl(playerControl);
bulletAppState.getPhysicsSpace().add(playerControl);[/java]
The problem is that I can put any value, it doesn’t work… The gravity stays (0, -2, 0) for the player.
What am i doing wrong ?
Thank you for your answer.