From 3e1146aadf90cc84ddd38bb3f02da8133b6f9862 Mon Sep 17 00:00:00 2001 From: EliteMasterEric Date: Tue, 7 Nov 2023 18:32:00 -0500 Subject: [PATCH 1/4] Fix bug where getDirection didn't work in scripts. --- assets | 2 +- source/funkin/data/song/SongData.hx | 32 ++++++++++++++--------------- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/assets b/assets index e634c8f50..5d5a860af 160000 --- a/assets +++ b/assets @@ -1 +1 @@ -Subproject commit e634c8f50c34845097283e0f411e1f89409e1498 +Subproject commit 5d5a860af517ef0cf2aa39c537eb228c7ae803d0 diff --git a/source/funkin/data/song/SongData.hx b/source/funkin/data/song/SongData.hx index 783f52a64..29ca28036 100644 --- a/source/funkin/data/song/SongData.hx +++ b/source/funkin/data/song/SongData.hx @@ -658,6 +658,22 @@ class SongNoteDataRaw this.kind = kind; } + /** + * The direction of the note, if applicable. + * Strips the strumline index from the data. + * + * 0 = left, 1 = down, 2 = up, 3 = right + */ + public inline function getDirection(strumlineSize:Int = 4):Int + { + return this.data % strumlineSize; + } + + public function getDirectionName(strumlineSize:Int = 4):String + { + return SongNoteData.buildDirectionName(this.data, strumlineSize); + } + @:jignored var _stepTime:Null = null; @@ -714,22 +730,6 @@ abstract SongNoteData(SongNoteDataRaw) from SongNoteDataRaw to SongNoteDataRaw this = new SongNoteDataRaw(time, data, length, kind); } - /** - * The direction of the note, if applicable. - * Strips the strumline index from the data. - * - * 0 = left, 1 = down, 2 = up, 3 = right - */ - public inline function getDirection(strumlineSize:Int = 4):Int - { - return this.data % strumlineSize; - } - - public function getDirectionName(strumlineSize:Int = 4):String - { - return SongNoteData.buildDirectionName(this.data, strumlineSize); - } - public static function buildDirectionName(data:Int, strumlineSize:Int = 4):String { switch (data % strumlineSize) From 2c9b8a115fde80f9ad75494164b791fa5fe55f1e Mon Sep 17 00:00:00 2001 From: EliteMasterEric Date: Wed, 15 Nov 2023 00:49:23 -0500 Subject: [PATCH 2/4] Update assets commit --- assets | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets b/assets index 5d5a860af..fb0a5fb09 160000 --- a/assets +++ b/assets @@ -1 +1 @@ -Subproject commit 5d5a860af517ef0cf2aa39c537eb228c7ae803d0 +Subproject commit fb0a5fb09fb966e95433d9cfb45826a89a1c5870 From 398b2e386e840c07c9522eb922b060253953dca3 Mon Sep 17 00:00:00 2001 From: EliteMasterEric Date: Wed, 15 Nov 2023 11:30:38 -0500 Subject: [PATCH 3/4] Remove wonky Spectrogram code --- .../ui/debug/charting/ChartEditorState.hx | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/source/funkin/ui/debug/charting/ChartEditorState.hx b/source/funkin/ui/debug/charting/ChartEditorState.hx index aa5372327..67c4e1fc4 100644 --- a/source/funkin/ui/debug/charting/ChartEditorState.hx +++ b/source/funkin/ui/debug/charting/ChartEditorState.hx @@ -1237,11 +1237,6 @@ class ChartEditorState extends HaxeUIState */ var gridGhostEvent:Null = null; - /** - * The waveform which (optionally) displays over the grid, underneath the notes and playhead. - */ - var gridSpectrogram:Null = null; - /** * The sprite used to display the note preview area. * We move this up and down to scroll the preview. @@ -1480,7 +1475,6 @@ class ChartEditorState extends HaxeUIState this.updateTheme(); buildGrid(); - // buildSpectrogram(audioInstTrack); buildNotePreview(); buildSelectionBox(); @@ -1881,16 +1875,6 @@ class ChartEditorState extends HaxeUIState } } - function buildSpectrogram(target:FlxSound):Void - { - gridSpectrogram = new PolygonSpectogram(FlxG.sound.music, FlxColor.RED, FlxG.height / 2, Math.floor(FlxG.height / 2)); - gridSpectrogram.x += 170; - gridSpectrogram.scrollFactor.set(); - gridSpectrogram.waveAmplitude = 50; - gridSpectrogram.visType = UPDATED; - add(gridSpectrogram); - } - /** * Builds the group that will hold all the notes. */ @@ -4857,8 +4841,6 @@ class ChartEditorState extends HaxeUIState gridPlayheadScrollArea.setGraphicSize(Std.int(gridPlayheadScrollArea.width), songLengthInPixels); gridPlayheadScrollArea.updateHitbox(); } - - buildSpectrogram(audioInstTrack); } else { From add4036911a63f14a61494cd292d6c5b47514725 Mon Sep 17 00:00:00 2001 From: Cameron Taylor Date: Wed, 15 Nov 2023 19:51:20 -0500 Subject: [PATCH 4/4] assets update --- assets | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets b/assets index fb0a5fb09..3b05b0fdd 160000 --- a/assets +++ b/assets @@ -1 +1 @@ -Subproject commit fb0a5fb09fb966e95433d9cfb45826a89a1c5870 +Subproject commit 3b05b0fdd8e3b2cd09b9e4e415c186bae8e3b7d3