IEnumerator RightHit() { LiMoRecv.SendVibEffect((int)LiMoConstant.ChairVibratorID.c_VIBID_Chair_Top_Right + (int)LiMoConstant.ChairVibratorID.c_VIBID_Chair_Bottom_Right, 180, 200); yield return(new WaitForSeconds(0.15f)); LiMoRecv.SendVibEffect((int)LiMoConstant.ChairVibratorID.c_VIBID_Chair_Top_Right + (int)LiMoConstant.ChairVibratorID.c_VIBID_Chair_Bottom_Right, 120, 200); }
IEnumerator BigHit() { LiMoRecv.SendVibEffect((int)LiMoConstant.ChairVibratorID.c_VIBID_Chair_Center_Center, 120, 200); yield return(new WaitForSeconds(0.15f)); LiMoRecv.SendVibEffect((int)LiMoConstant.ChairVibratorID.c_VIBID_Chair_ALL, 180, 300); yield return(new WaitForSeconds(0.2f)); LiMoRecv.SendVibEffect((int)LiMoConstant.ChairVibratorID.c_VIBID_Chair_Center_Center, 120, 100); }
// Update is called once per frame void Update() { //Debug.Log(Input.GetAxis("Horizontal") + "," + Input.GetAxis("Vertical")); //for(int i=1; i<= 28;i++) //{ // string dname; // dname = "H"+i; // float value1 = Input.GetAxisRaw(dname) * 1000; // float value2 = Input.GetAxis(dname) * 1000; // Debug.Log(dname +"," +value1+","+value2); //} //if (Input.GetButtonDown(InputMap.instance.GetLeftTriggerName())) //{ // KiWiRecv.SendVibEffectSmooth(0, (uint)LCnt, 150); //} if (LiMoInput.instance.LeftTriggerDown) { LeftRemainTime -= Time.deltaTime; if (LeftRemainTime <= 0) { LeftRemainTime = 0.2f; //KiWiRecv.SendVibEffectSmooth(0, (uint)LCnt, 150); LiMoRecv.SendVibEffect(0, (int)LCnt, 150); } } else { LeftRemainTime = 0; } if (LiMoInput.instance.LeftActionDown) { LCnt -= 10; if (LCnt <= 0) { LCnt = 199; } } if (LiMoInput.instance.RightTriggerDown) { LiMoRecv.SendVibEffect(3, (int)RCnt, 150); RCnt -= 10; if (LCnt <= 0) { RCnt = 199; } } }