- Home /
 
 
               Question by 
               Anonymoose · Jul 20, 2016 at 09:02 PM · 
                c#3djumpdouble jump  
              
 
              How can I edit this script to double jump?
I am using an asset called Standard Assets for Unity 4.6 and i am trying to edit the script to allow the player to Double Jump If you can help in anyway that would be fantastic!
    // check whether conditions are right to allow a jump:
             bool animationGrounded = animator.GetCurrentAnimatorStateInfo(0).IsName("Grounded");
             bool okToRepeatJump = Time.time > lastAirTime + advancedSettings.jumpRepeatDelayTime;
 
             if (jumpInput && !crouchInput && okToRepeatJump && animationGrounded)
             {
                 // jump!
                 onGround = false;
                 velocity = moveInput*airSpeed;
                 velocity.y = jumpPower;
             }
 
              
               Comment
              
 
               
              Your answer
 
             Follow this Question
Related Questions
Distribute terrain in zones 3 Answers
3d Animated Jump Script 0 Answers
Booleans are not working 1 Answer
3D coyote time 1 Answer