if (cc.isGrounded)
{
moveDirection = new Vector3(0, 0, Input.GetAxis("Horizontal"));
moveDirection = transform.TransformDirection(moveDirection);
moveDirection *= speed;
if (Input.GetKeyDown(KeyCode.Space))
{
animator.SetBool("jump01",true);
moveDirection = new Vector3 (0, 0, h);
moveDirection.y = jumpspeed;
num = 1;
}
else if (Input.GetKeyDown(KeyCode.Space))
{
if (num == 1)
{
animator.SetBool("jump02", true);
moveDirection.y = jumpspeed;
}
}
moveDirection.y -= gravity * Time.deltaTime;
cc.SimpleMove(moveDirection * Time.deltaTime);
animator.SetBool("jump02",false);
}