Exemple #1
0
    private void Action(SteamVR_RenderModel arg0, bool arg1)
    {
        InteractionTechnique interactionTechnique = TaskController.Instance.GetInteractionTechnique();

        if (interactionTechnique && !interactionTechnique.moveHoverPoint)
        {
            return;
        }

        Hand hand = arg0.GetComponentInParent <Hand>();

        if (!hand)
        {
            return;
        }

        Transform hoverPoint = hand.transform.Find("HoverPoint");

        if (!hoverPoint)
        {
            return;
        }

        if (arg0.renderModelName.Contains("vive_cosmos"))
        {
            hoverPoint.localPosition = ViveCosmosHoverPointPosition;
        }
        else if (arg0.renderModelName.Contains("controller_vive"))
        {
            hoverPoint.localPosition = ViveProHoverPointPosition;
        }
    }