mirror of
https://github.com/RHeavenStudio/HeavenStudio.git
synced 2025-06-12 13:47:38 +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:
@ -129,11 +129,7 @@ namespace HeavenStudio.Editor.Track
|
||||
}
|
||||
|
||||
private void AddTempoChange(bool create, Beatmap.TempoChange tempoChange_ = null)
|
||||
{
|
||||
// TEMP: DISABLED UNTIL CRITICAL FIXES
|
||||
if (create)
|
||||
return;
|
||||
|
||||
{
|
||||
GameObject tempoChange = Instantiate(RefTempoChange.gameObject, this.transform);
|
||||
|
||||
tempoChange.transform.GetChild(0).GetComponent<Image>().color = EditorTheme.theme.properties.TempoLayerCol.Hex2RGB();
|
||||
|
@ -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