Exemple #1
0
 void Awake()
 {
     if (!Application.isPlaying)
     {
         return;
     }
     MidiPlayer.deviceNum = midiOutputDevice;
     MidiPlayer.Start();
     Metronome.setBPM(bpm);
     previousBpm = bpm;
 }
Exemple #2
0
        void Update()
        {
            if (!Application.isPlaying)
            {
                return;
            }
            MidiPlayer.Update();

            if (bpm != previousBpm)
            {
                Metronome.setBPM(bpm);
                previousBpm = bpm;
            }
        }
Exemple #3
0
 public static void StartMetronome(int p_BPM)
 {
     Metronome.setBPM(p_BPM);
     metronomeStartTimeMs = AudioSettings.dspTime * 1000;
 }
Exemple #4
0
 public static void SetBPM(int p_BPM)
 {
     Metronome.setBPM(p_BPM);
 }