'Piano keys with unity sync

What's up guys! I'm developing a game like Piano Tiles, the keys are already generated by themselves... I managed to get the current tempo of the beats of the songs to try to present keys with a certain synchronization. However, I don't know how to apply this time to the keys. Does anyone have any idea how to do this so that the keystroke matches the beat of the song?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source