Movement script

I'm trying to wrap my mind around the Platformer controller script from the 2d Platformer tutorial, but I have some doubts I don't seem to be able to solve by reading the script and reference manuals. Here goes. On this piece of code:

function ApplyJumping () {
// Prevent jumping too fast after each other
if (jump.lastTime + jump.repeatTime > Time.time)

if (controller.isGrounded) {
    // Jump
    // - Only when pressing the button down
    // - With a timeout so you can press the button slightly before landing     
    if (jump.enabled && Time.time < jump.lastButtonTime + jump.timeout) {
        movement.verticalSpeed = CalculateJumpVerticalSpeed (jump.height);
        movement.inAirVelocity = lastPlatformVelocity;
        SendMessage ("DidJump", SendMessageOptions.DontRequireReceiver);


I don't get what the

if (jump.enabled && Time.time < jump.lastButtonTime + jump.timeout)

bit does. The variables are pretty self-explanatory, (jump is a custom class with a number of variables, timeout is a constant previously set at 0.15)

To me this looks as if jumping will only occur if the button is pressed before timeout time has passed after it was pressed last time. Which doesn't make sense (I can only jump if I keep jumping?). I'm sure I'm missing something, I just can't find out.

Please let me know if you need more details.

Well, you are right, take a look t othe comment ' With a timeout so you can press the button slightly before landing' so in case you are not still grounded you can jump again...

but i am sure there is another part of code where you can jump when you are grounded :)

I found this, which I think is what applies the initial upwards speed to start the jump (in particular the else if statement).

if (extraPowerJump)
    else if (controller.isGrounded)
        movement.verticalSpeed = -movement.gravity * Time.deltaTime;
        movement.verticalSpeed -= movement.gravity * Time.deltaTime;

However, I still don't understand the minus sign?

-movement.gravity * Time.deltaTime

Wouldn't that result in a downwards speed? (gravity is stated at the top of the script as

var gravity = 60.0;