solid tick-based metronome and refactor
ooo, Math.max, that's going to make a big difference