# How to Quantise to global clock in Unity?

**URL:** <https://qa.fmod.com/t/how-to-quantise-to-global-clock-in-unity/13258>\
**Category:** FMOD Studio\
**Created:** [June 28, 2017, 1:39pm UTC](https://qa.fmod.com/t/how-to-quantise-to-global-clock-in-unity/13258 "2017-06-28T13:39:48Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bassdrummer](https://avatars.discourse-cdn.com/v4/letter/b/96bed5/32.png) [@Bassdrummer](https://qa.fmod.com/u/Bassdrummer)\
**Post date:** [June 28, 2017, 1:39pm UTC](https://qa.fmod.com/t/how-to-quantise-to-global-clock-in-unity/13258/1 "2017-06-28T13:39:48Z")

</div>

Hi All,

I’m trying to create a music game on the vive that uses loops set to 140. then the player uses gestures to create a melody over the top.

At the moment I’ve divided the scale into separate events that are linked to the Y axis and trigger like a stepped theremin.  
My question is how do i quantise these triggered notes to the tempo of the loop. If they are all set to be quantised to an 8th note in Fmod, will unity recognise that? or would i have to get unity to be the ‘global clock’

Thanks for your time all!

ed

---

<div class="post-metadata">

**Author:** ![cameron-fmod](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/cameron-fmod/32/261_2.png) [@cameron-fmod](https://qa.fmod.com/u/cameron-fmod)\
**Post date:** [July 2, 2017, 10:40pm UTC](https://qa.fmod.com/t/how-to-quantise-to-global-clock-in-unity/13258/2 "2017-07-02T22:40:32Z")

</div>

Using [timeline callbacks](http://www.fmod.org/documentation#content/generated/engine_new_unity/script_example_timeline.html) you can fire of events at your will. Eg. if the eighth bar is hit.  
This then relies on having the events setup with a tempo marker in FMOD Studio.
