mirror of
https://github.com/RHeavenStudio/HeavenStudio.git
synced 2025-06-12 08:47:37 +02:00
Editor: Timeline now scales to fit song length
This commit is contained in:
@ -189,6 +189,15 @@ namespace RhythmHeavenMania.Editor.Track
|
||||
AutoBtnUpdate();
|
||||
}
|
||||
|
||||
public void FitToSong()
|
||||
{
|
||||
var currentSizeDelta = TimelineContent.sizeDelta;
|
||||
float songBeats = Conductor.instance.SongLengthInBeats();
|
||||
if (songBeats == 0) songBeats = 320;
|
||||
else songBeats += 10;
|
||||
TimelineContent.sizeDelta = new Vector2(songBeats, currentSizeDelta.y);
|
||||
}
|
||||
|
||||
public void AutoBtnUpdate()
|
||||
{
|
||||
var animName = GameManager.instance.autoplay ? "Idle" : "Disabled";
|
||||
|
Reference in New Issue
Block a user