|
-Here, `player.setJumpSpeed(20)` has no visible effect because its value is overridden when `jump(new Vector3f(0,20f,0)` is invoked in the onAction(). If you were to replace `jump(new Vector3f(0,20f,0)` with `jump(new Vector3f(0f,60f,0f))`, then the player jumps faster and higher, using the jump speed, as would be expected.
|
|
|
|
|
|
+Here, `player.setJumpSpeed(20)` has no visible effect because its value is overridden when `jump(new Vector3f(0,20f,0)` is invoked in the onAction(). If you were to replace `jump(new Vector3f(0,20f,0)` with `jump(new Vector3f(0f,60f,0f))`, then the player jumps faster and higher, as would be expected.
|
|
If you were using the "`jBullet`" library for physics, you would manipulate the jump speed and calling jump would have the same effect.
|
|
If you were using the "`jBullet`" library for physics, you would manipulate the jump speed and calling jump would have the same effect.
|