Home>

I'm trying to make a simple program that uses VR and Leap Motion in unity to pick up the coins floating in the VR space by hand (disappears when touched).
Even if a Leap Motion hand model touches the coin, it is in trouble because the collision is not detected.

-The model of the hand uses a LeapRig in Leap Motion Core Asset with a Rigid Hand attached.

-I tried to make something to roll by tapping the box, I tried attaching it with a hand model with a rigid body attached to Cube, but nothing happened just because the hand model slipped through.

-I tried it with a rigid body and collider attached to the hand model, but it didn't change at all and the collision detection did not work.

・ Coins disappeared without problems when using Cube instead of hand model.

・ The following is the script of the coin itself. Collisions other than the hand model moved normally.

// When something collides
    void OnTriggerEnter (Collider hit)
    {
        Debug.Log ("collision");
        int start = script.gameStart;
        // The game has started and i am active
        if (start == 1&&sphere.activeSelf)
        {
            script.coinCount + = 1;
            Debug.Log (script.coinCount);
            Destroy (gameObject);
        }
    }
}

I'm sorry, thank you.