Beispiel #1
0
        public void Init()
        {
            DynamicMeshScript = GetComponent <ViveSR_Experience_DynamicMesh>();

            GameObject attachPointCanvas = ViveSR_Experience.instance.AttachPoint.transform.GetChild(ViveSR_Experience.instance.AttachPointIndex).transform.gameObject;

            DisplayMesh   = attachPointCanvas.transform.Find("TouchpadCanvas/DisplayText").GetComponent <Text>();
            LeftText      = attachPointCanvas.transform.Find("TouchpadCanvas/LeftText").GetComponent <Text>();
            RightText     = attachPointCanvas.transform.Find("TouchpadCanvas/RightText").GetComponent <Text>();
            ThrowableText = attachPointCanvas.transform.Find("TriggerCanvas/TriggerText").GetComponent <Text>();
            TriggerCanvas = attachPointCanvas.transform.Find("TriggerCanvas").gameObject;

            DynamicMeshScript.SetDynamicMesh(true);
            ViveSR_Experience_ControllerDelegate.triggerDelegate  += HandleTrigger;
            ViveSR_Experience_ControllerDelegate.touchpadDelegate += HandleTouchpad;
        }
 protected override void StartToDo()
 {
     DynamicMeshScript        = GetComponent <ViveSR_Experience_DynamicMesh>();
     ThisButtonTypeNum        = (int)SubBtnType;
     dartGeneratorMgr_dynamic = ViveSR_Experience_Demo.instance.DartGeneratorMgrs[DartGeneratorIndex.ForDynamic];
 }