private void updateJumping()
 {
     if ((Input.GetButtonDown("Jump") == true ||
          _MobileInput.GetButtonDown("Jump")) &&
         jumpsRemaining > 0 && totalJumpFrames < 0)
     {
         jumped = true;
         //CBUG.Log("Jumped is true!");
         jumpsRemaining -= 1;
         totalJumpFrames = jumpLag;
     }
     totalJumpFrames -= 1;
 }
Esempio n. 2
0
    private void updateJumping()
    {
        //bool K = ();

        CBUG.Do(Input.GetAxisRaw("Jump") + "");

        if ((Input.GetButtonDown("Jump") == true ||
             _MobileInput.GetButtonDown("Jump") || Input.GetAxisRaw("Jump") > 0f) &&
            jumpsRemaining > 0 && totalJumpFrames < 0)
        {
            jumped = true;
            //CBUG.Log("Jumped is true!");
            jumpsRemaining -= 1;
            totalJumpFrames = jumpLag;
        }
        totalJumpFrames -= 1;
    }