Пример #1
0
 public void HandleTickChange(NotationTime currentTime)
 {
     if (tickUnlockTime.TimeAsTicks() == Metronome.Instance.currentTime.TimeAsTicks())
     {
         tickLock = false;
     }
 }
Пример #2
0
    public void HandleTickChange(NotationTime currentTime)
    {
        if (currentTime.TimeAsTicks() == nextPlay.TimeAsTicks() - 1)
        {
            double nextPlayTime = Metronome.Instance.GetFutureTime(nextPlay);
            //sources[nextSource].clip = nextClip.clip;
            sources[nextSource].clip   = nextClip.clip;
            sources[nextSource].volume = 0.4f;
            sources[nextSource].PlayScheduled(nextPlayTime);
            //Set next time to play
            currentClip = nextClip;
            nextPlay.Add(currentClip.length);

            nextSource = (nextSource + 1) % sources.Length;
        }
    }