void Update() { Debug.Log("------------------//////////---------------"); if (MicrophoneInput.IsRecordingMain()) { if (printDBValue) { Debug.Log("DB Value: " + MicrophoneInput.dbValueMain); } if (printRMSValue) { Debug.Log("RMS Value: " + MicrophoneInput.rmsValueMain); } if (printPitchValue) { Debug.Log("Pitch Value: " + MicrophoneInput.pitchValueMain); } if (Input.GetKeyDown(KeyCode.T)) { Debug.Log("STOP"); MicrophoneInput.StopRecordingMain(); } } else { Debug.Log("Microphone is not recording."); if (Input.GetKeyDown(KeyCode.T)) { Debug.Log("START"); MicrophoneInput.StartRecordingMain(); } } Debug.Log("---------------------------------------"); }