- Home /
 
How long addforce applied?
Hi 
 I thought that my answer is Time.deltatime but when I use it in below function the function output where wrong and my character jump about two times higher:
     public float calculateMaximumJumpingHeight()
         {
             float verticalSpeed = (Time.deltaTime *
                     ((jumpForce.y / GetComponent<Rigidbody2D>().mass) + Physics2D.gravity.y));
             return (-1 * verticalSpeed * verticalSpeed) /(2 * Physics2D.gravity.y);
         }
 
               so, why this doesn't give me the true answer? 
or how to calculate maximum high of the projectile?
               Comment
              
 
               
              For jumping I would highly recommend using Force$$anonymous$$ode.VelocityChange ins$$anonymous$$d of Force$$anonymous$$ode.Force. That way you don't have to factor in mass or time.
Your answer