0
$\begingroup$

I would like to be able to have a min jump height as 1 meter, and max jup height as 3 meter. When the spacebar is pressed and released quickly, the player jumps up one meter. When the spacebar is held down for a longer time, the player jumps up 3 meters instead of one.

Is this possible to make in the logic bricks or python for BGE?

$\endgroup$

1 Answer 1

2
$\begingroup$

Yes, it is possible.

Typically you measure the time between pressed and released. Minimum is one frame, so you will always been able to measure the time.

You need to define how you want to convert the time to jump height (or force or velocity or whatever.

enter image description here

Due to it's dynamic nature I suggest to implement the usage of the result that in Python.

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .