Merge remote-tracking branch 'upstream/main'

This commit is contained in:
Ne_Eo
2024-11-29 22:02:37 +01:00
22 changed files with 214 additions and 38 deletions
+30
View File
@@ -332,6 +332,7 @@ class Charter extends UIState {
null,
{
label: "↑ Speed 25%",
keybind: [PERIOD],
onSelect: _playback_speed_raise
},
{
@@ -340,6 +341,7 @@ class Charter extends UIState {
},
{
label: "↓ Speed 25%",
keybind: [COMMA],
onSelect: _playback_speed_lower
},
null,
@@ -353,6 +355,22 @@ class Charter extends UIState {
keybind: [D],
onSelect: _playback_forward
},
{
label: "Go to start of section",
keybind: [SHIFT, S],
onSelect: _playback_section_start
},
null,
{
label: "Go back a step",
keybind: [W],
onSelect: _playback_back_step
},
{
label: "Go forward a step",
keybind: [S],
onSelect: _playback_forward_step
},
null,
{
label: "Metronome",
@@ -1583,6 +1601,18 @@ class Charter extends UIState {
if (FlxG.sound.music.playing) return;
Conductor.songPosition += (Conductor.beatsPerMeasure * __crochet);
}
function _playback_section_start(_) {
if(FlxG.sound.music.playing) return;
Conductor.songPosition = (Conductor.beatsPerMeasure * (60000 / Conductor.bpm)) * curMeasure;
}
function _playback_back_step(_) {
if (FlxG.sound.music.playing) return;
Conductor.songPosition -= Conductor.stepCrochet;
}
function _playback_forward_step(_) {
if (FlxG.sound.music.playing) return;
Conductor.songPosition += Conductor.stepCrochet;
}
function _song_start(_) {
if (FlxG.sound.music.playing) return;
Conductor.songPosition = 0;