Exemple #1
0
 public void HideCardZoomed()
 {
     if (SwipeManager.IsSwiping())
     {
         return;
     }
     zoomPanel.gameObject.SetActive(false);
 }
 // Update is called once per frame
 void Update()
 {
     Debug.Log(SwipeManager.IsSwiping());
     if (SwipeManager.IsSwiping())
     {
         // rotate the object
         obj.transform.Rotate(rotateStep);
     }
 }
Exemple #3
0
    void Update()
    {
        if (SwipeManager.IsSwipingLeft())
        {
        }

        if (SwipeManager.IsSwiping())
        {
        }
    }
    void MoveOnSwipe()
    {
        if (SwipeManager.IsSwipingUp())
        {
            if (Time.time > nextJump)
            {
                nextJump             = Time.time + jumpRate;
                myRigidBody.velocity = new Vector3(myRigidBody.velocity.x, 5f, 0f);
            }
        }
        if (SwipeManager.IsSwiping())
        {
            //shooting
            //isFire=true;

            /*Debug.Log("tragem tragem tragem ");
             * if(Time.time>nextFire){
             *      nextFire=Time.time+fireRate;
             *      myAnim.Play("WalkAndFire");
             *      Instantiate(bullet,bulletSpawn.position,bulletSpawn.rotation);
             *
             * }/* */
        }
        //}
        if (SwipeManager.IsSwipingLeft())
        {
            moveSpeed = moveSpeed - 1;
            if (moveSpeed <= 1)
            {
                moveSpeed = 1;
            }
        }
        if (SwipeManager.IsSwipingRight())
        {
            moveSpeed = moveSpeed + 1;
            if (moveSpeed >= 10)
            {
                moveSpeed = 10;
            }
        }
    }
Exemple #5
0
    // Update is called once per frame
    void Update()
    {
        if (SwipeManager.IsSwipingLeft())
        {
            Debug.Log("swiped left ");
            book.FlipRightPage();
        }

        if (SwipeManager.IsSwipingRight())
        {
            Debug.Log("swiped right ");
            book.FlipLeftPage();
        }

        // OR

        if (SwipeManager.IsSwiping())
        {
            // do something
        }
    }