mirror of
https://github.com/RHeavenStudio/HeavenStudio.git
synced 2025-06-13 09:57:37 +02:00
Tempo changes restored (#92)
* Prepwork for seeking + tempo change fixes TODO: make playing after seeking function (I'll need help with the offset stuff so if anyone can push to this branch please do) * functions to get the beat from a song position will need more testing but I think it works well enough to get into prod thanks @wooningcharithri#7419 for the psuedo-code
This commit is contained in:
@ -296,7 +296,7 @@ namespace HeavenStudio.Editor.Track
|
||||
if (movingPlayback)
|
||||
{
|
||||
RectTransformUtility.ScreenPointToLocalPointInRectangle(TimelineContent, Input.mousePosition, Editor.instance.EditorCamera, out lastMousePos);
|
||||
TimelineSlider.localPosition = new Vector3(Mathf.Clamp(Mathp.Round2Nearest(lastMousePos.x + 0.12f, Timeline.SnapInterval()), 0, Mathf.Infinity), TimelineSlider.transform.localPosition.y);
|
||||
TimelineSlider.localPosition = new Vector3(Mathf.Max(Mathp.Round2Nearest(lastMousePos.x + 0.12f, Timeline.SnapInterval()), 0), TimelineSlider.transform.localPosition.y);
|
||||
|
||||
if (TimelineSlider.localPosition.x != lastBeatPos)
|
||||
Conductor.instance.SetBeat(TimelineSlider.transform.localPosition.x);
|
||||
|
Reference in New Issue
Block a user