예제 #1
0
    ///For single touch allowed only
    private void SingleTouch()
    {
        Touch touch = Input.GetTouch(0);

        if (touch.phase == TouchPhase.Began)
        {
            tap.Trigger(null);
        }
    }
예제 #2
0
    // Update is called once per frame
    void Update()
    {
        if (Input.GetKeyUp(KeyCode.Space))
        {
            tap.Trigger(null);
        }

        if (Input.GetKeyUp(KeyCode.Mouse0))
        {
            tap.Trigger(null);
        }
    }