From 0cb23f7972af48197b150713ff193a3bc3d7f77b Mon Sep 17 00:00:00 2001 From: Detoria Date: Wed, 24 Mar 2021 04:48:14 -0300 Subject: [PATCH 01/10] Fixed Note Speed --- source/Note.hx | 58 +++++++++++++++++++++---------- source/OptionsMenu.hx | 80 +++++++++++++++++++++++++++++++++++++++---- source/PlayState.hx | 11 ++++-- 3 files changed, 121 insertions(+), 28 deletions(-) diff --git a/source/Note.hx b/source/Note.hx index c7cde28..88793ec 100644 --- a/source/Note.hx +++ b/source/Note.hx @@ -40,8 +40,9 @@ class Note extends FlxSprite if (prevNote == null) prevNote = this; - if (FlxG.save.data.downscroll) - flipY = true; + // And have up and down arrows flipped too? Nop + /* if (FlxG.save.data.downscroll) + flipY = true; */ this.prevNote = prevNote; isSustainNote = sustainNote; @@ -49,6 +50,7 @@ class Note extends FlxSprite x += 50; // MAKE SURE ITS DEFINITELY OFF SCREEN? y -= 2000; + this.strumTime = strumTime + FlxG.save.data.offset; this.noteData = noteData; @@ -64,20 +66,30 @@ class Note extends FlxSprite animation.add('redScroll', [7]); animation.add('blueScroll', [5]); animation.add('purpleScroll', [4]); - + + // Hold piece + animation.add('purplehold', [0]); + animation.add('greenhold', [2]); + animation.add('redhold', [3]); + animation.add('bluehold', [1]); + if (isSustainNote) { loadGraphic(Paths.image('weeb/pixelUI/arrowEnds'), true, 7, 6); - animation.add('purpleholdend', [4]); - animation.add('greenholdend', [6]); - animation.add('redholdend', [7]); - animation.add('blueholdend', [5]); - - animation.add('purplehold', [0]); - animation.add('greenhold', [2]); - animation.add('redhold', [3]); - animation.add('bluehold', [1]); + if(!FlxG.save.data.downscroll) + { + // Trail end + animation.add('purpleholdend', [4]); + animation.add('greenholdend', [6]); + animation.add('redholdend', [7]); + animation.add('blueholdend', [5]); + }else { + animation.add('purpleholdend', [4], 0, false, false, true); + animation.add('greenholdend', [6], 0, false, false, true); + animation.add('redholdend', [7], 0, false, false, true); + animation.add('blueholdend', [5], 0, false, false, true); + } } setGraphicSize(Std.int(width * PlayState.daPixelZoom)); @@ -90,16 +102,24 @@ class Note extends FlxSprite animation.addByPrefix('redScroll', 'red0'); animation.addByPrefix('blueScroll', 'blue0'); animation.addByPrefix('purpleScroll', 'purple0'); - - animation.addByPrefix('purpleholdend', 'pruple end hold'); - animation.addByPrefix('greenholdend', 'green hold end'); - animation.addByPrefix('redholdend', 'red hold end'); - animation.addByPrefix('blueholdend', 'blue hold end'); - + animation.addByPrefix('purplehold', 'purple hold piece'); animation.addByPrefix('greenhold', 'green hold piece'); animation.addByPrefix('redhold', 'red hold piece'); animation.addByPrefix('bluehold', 'blue hold piece'); + + if(!FlxG.save.data.downscroll) + { + animation.addByPrefix('purpleholdend', 'pruple end hold'); + animation.addByPrefix('greenholdend', 'green hold end'); + animation.addByPrefix('redholdend', 'red hold end'); + animation.addByPrefix('blueholdend', 'blue hold end'); + }else { + animation.addByPrefix('purpleholdend', 'pruple end hold', 0, false, false, true); + animation.addByPrefix('greenholdend', 'green hold end', 0, false, false, true); + animation.addByPrefix('redholdend', 'red hold end', 0, false, false, true); + animation.addByPrefix('blueholdend', 'blue hold end', 0, false, false, true); + } setGraphicSize(Std.int(width * 0.7)); updateHitbox(); @@ -164,7 +184,7 @@ class Note extends FlxSprite prevNote.animation.play('redhold'); } - prevNote.scale.y *= Conductor.stepCrochet / 100 * 1.5 * PlayState.SONG.speed; + prevNote.scale.y *= Conductor.stepCrochet / 100 * 1.5 * FlxG.save.data.noteSpeed; prevNote.updateHitbox(); // prevNote.setGraphicSize(); } diff --git a/source/OptionsMenu.hx b/source/OptionsMenu.hx index 68ee6e7..1dea8a7 100644 --- a/source/OptionsMenu.hx +++ b/source/OptionsMenu.hx @@ -17,6 +17,8 @@ class OptionsMenu extends MusicBeatState { var selector:FlxText; var curSelected:Int = 0; + var chartSpeed:FlxText; + var speedState:String; var controlsStrings:Array = []; @@ -31,6 +33,7 @@ class OptionsMenu extends MusicBeatState "\n" + (FlxG.save.data.downscroll ? 'Downscroll' : 'Upscroll') + "\nAccuracy " + (!FlxG.save.data.accuracyDisplay ? "off" : "on") + "\nSong Position " + (!FlxG.save.data.songPosition ? "off" : "on") + + "\nNote Speed" + "\nEtterna Mode " + (!FlxG.save.data.etternaMode ? "off" : "on") + "\nLoad replays"); @@ -61,6 +64,20 @@ class OptionsMenu extends MusicBeatState versionShit.setFormat("VCR OSD Mono", 16, FlxColor.WHITE, LEFT, FlxTextBorderStyle.OUTLINE, FlxColor.BLACK); add(versionShit); + var tmp_Speed:Float = FlxG.save.data.noteSpeed; + + chartSpeed = new FlxText(FlxG.width - 387, FlxG.height - 18, 0, "Note Speed (Hover, then Left and Right): " + tmp_Speed, 12); + chartSpeed.scrollFactor.set(); + chartSpeed.setFormat("VCR OSD Mono", 16, FlxColor.WHITE, LEFT, FlxTextBorderStyle.OUTLINE, FlxColor.BLACK); + + if(tmp_Speed == -1) chartSpeed.x = FlxG.width - 470; + else if(tmp_Speed == 1.5 || tmp_Speed == 2.5 || tmp_Speed == 3.5) chartSpeed.x = FlxG.width - 405; + else chartSpeed.x = FlxG.width - 387; + + if(FlxG.save.data.noteSpeed > 0) chartSpeed.text = "Note Speed (Hover, then Left and Right): " + FlxG.save.data.noteSpeed.toString(); + else chartSpeed.text = "Note Speed (Hover, then Left and Right): Song Based"; + add(chartSpeed); + super.create(); } @@ -77,21 +94,72 @@ class OptionsMenu extends MusicBeatState if (controls.RIGHT_R) { - FlxG.save.data.offset++; - versionShit.text = "Offset (Left, Right): " + FlxG.save.data.offset; + if(curSelected != 5) + { + FlxG.save.data.offset++; + versionShit.text = "Offset (Left, Right): " + FlxG.save.data.offset; + }else { + if(FlxG.save.data.noteSpeed < 4.0) + if(FlxG.save.data.noteSpeed == -1) FlxG.save.data.noteSpeed = 1.0; + else FlxG.save.data.noteSpeed += 0.5; + + grpControls.remove(grpControls.members[curSelected]); + var ctrl:Alphabet = new Alphabet(0, (70 * curSelected) + 30, "Note Speed", true, false); + ctrl.isMenuItem = true; + ctrl.targetY = curSelected - 5; + grpControls.add(ctrl); + + if(FlxG.save.data.noteSpeed > 0) speedState = FlxG.save.data.noteSpeed.toString(); + else speedState = "Song Based"; + + chartSpeed.text = "Note Speed (Hover, then Left and Right): " + speedState; + + trace(FlxG.save.data.noteSpeed); + } } if (controls.LEFT_R) + { + if(curSelected != 5) { FlxG.save.data.offset--; versionShit.text = "Offset (Left, Right): " + FlxG.save.data.offset; + }else { + if(FlxG.save.data.noteSpeed > 1.0) FlxG.save.data.noteSpeed -= 0.5; + else FlxG.save.data.noteSpeed = -1; + + trace(FlxG.save.data.noteSpeed); + var speedState = ""; + + if(FlxG.save.data.noteSpeed > 0) speedState = FlxG.save.data.noteSpeed.toString(); + else speedState = "Song Based"; + + chartSpeed.text = "Note Speed (Hover, then Left and Right): " + speedState; + + grpControls.remove(grpControls.members[curSelected]); + var ctrl:Alphabet = new Alphabet(0, (70 * curSelected) + 30, "Note Speed", true, false); + ctrl.isMenuItem = true; + ctrl.targetY = curSelected - 5; + grpControls.add(ctrl); + + trace(FlxG.save.data.noteSpeed); } + } + if(controls.LEFT_R && curSelected == 5 || controls.RIGHT_R && curSelected == 5 ) + { + var tmp_Speed:Float = FlxG.save.data.noteSpeed; + + if(tmp_Speed == -1) chartSpeed.x = FlxG.width - 470; + else if(tmp_Speed == 1.5 || tmp_Speed == 2.5 || tmp_Speed == 3.5) chartSpeed.x = FlxG.width - 405; + else chartSpeed.x = FlxG.width - 387; + } if (controls.ACCEPT) { - if (curSelected != 6) + if (curSelected != 7 && curSelected != 5) grpControls.remove(grpControls.members[curSelected]); + switch(curSelected) { case 0: @@ -129,13 +197,13 @@ class OptionsMenu extends MusicBeatState ctrl.isMenuItem = true; ctrl.targetY = curSelected - 4; grpControls.add(ctrl); - case 5: + case 6: FlxG.save.data.etternaMode = !FlxG.save.data.etternaMode; var ctrl:Alphabet = new Alphabet(0, (70 * curSelected) + 30, "Etterna Mode " + (!FlxG.save.data.etternaMode ? "off" : "on"), true, false); ctrl.isMenuItem = true; - ctrl.targetY = curSelected - 5; + ctrl.targetY = curSelected - 6; grpControls.add(ctrl); - case 6: + case 7: trace('switch'); FlxG.switchState(new LoadReplayState()); } diff --git a/source/PlayState.hx b/source/PlayState.hx index e4b9508..cdbc079 100644 --- a/source/PlayState.hx +++ b/source/PlayState.hx @@ -1878,9 +1878,14 @@ class PlayState extends MusicBeatState } if (FlxG.save.data.downscroll) - daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (-0.45 * FlxMath.roundDecimal(SONG.speed, 2))); + if(FlxG.save.data.noteSpeed != -1) + daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (-0.45 * FlxMath.roundDecimal(FlxG.save.data.noteSpeed, 2))); + else daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (-0.45 * FlxMath.roundDecimal(SONG.speed, 2))); else - daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (0.45 * FlxMath.roundDecimal(SONG.speed, 2))); + if(FlxG.save.data.noteSpeed != -1) + daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (0.45 * FlxMath.roundDecimal(FlxG.save.data.noteSpeed, 2))); + else daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (0.45 * FlxMath.roundDecimal(SONG.speed, 2))); + //trace(daNote.y); // WIP interpolation shit? Need to fix the pause issue // daNote.y = (strumLine.y - (songTime - daNote.strumTime) * (0.45 * PlayState.SONG.speed)); @@ -3025,4 +3030,4 @@ class PlayState extends MusicBeatState } var curLight:Int = 0; -} +} \ No newline at end of file From 0b237f3b9e623ea0add7dd9cca10337240cab899 Mon Sep 17 00:00:00 2001 From: Detoria Date: Wed, 24 Mar 2021 18:15:40 -0300 Subject: [PATCH 02/10] Update .gitignore --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 7dbb7d6..c4bff8e 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ export/ +assets/ .vscode/ APIStuff.hx \ No newline at end of file From 172b879f33fd81738aed4f95f2a4a84b03a102d5 Mon Sep 17 00:00:00 2001 From: Detoria <44783518+theDetourist@users.noreply.github.com> Date: Wed, 24 Mar 2021 18:42:14 -0300 Subject: [PATCH 03/10] ignore dat --- .gitignore | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index c4bff8e..415caf3 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,3 @@ export/ -assets/ .vscode/ -APIStuff.hx \ No newline at end of file +APIStuff.hx From 4885afccaf369d4459118550e559afb0c8b59b74 Mon Sep 17 00:00:00 2001 From: Detoria <44783518+theDetourist@users.noreply.github.com> Date: Thu, 25 Mar 2021 03:44:35 -0300 Subject: [PATCH 04/10] Quick fix for song not ending Simple callback that got deleted last commit now brought back. --- source/PlayState.hx | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/source/PlayState.hx b/source/PlayState.hx index cdbc079..0e4b495 100644 --- a/source/PlayState.hx +++ b/source/PlayState.hx @@ -1131,6 +1131,8 @@ class PlayState extends MusicBeatState if (!paused) FlxG.sound.playMusic(Paths.inst(PlayState.SONG.song), 1, false); + + FlxG.sound.music.onComplete = endSong; vocals.play(); if (FlxG.save.data.songPosition) @@ -1878,14 +1880,9 @@ class PlayState extends MusicBeatState } if (FlxG.save.data.downscroll) - if(FlxG.save.data.noteSpeed != -1) - daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (-0.45 * FlxMath.roundDecimal(FlxG.save.data.noteSpeed, 2))); - else daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (-0.45 * FlxMath.roundDecimal(SONG.speed, 2))); + daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (-0.45 * FlxMath.roundDecimal(SONG.speed, 2))); else - if(FlxG.save.data.noteSpeed != -1) - daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (0.45 * FlxMath.roundDecimal(FlxG.save.data.noteSpeed, 2))); - else daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (0.45 * FlxMath.roundDecimal(SONG.speed, 2))); - + daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (0.45 * FlxMath.roundDecimal(SONG.speed, 2))); //trace(daNote.y); // WIP interpolation shit? Need to fix the pause issue // daNote.y = (strumLine.y - (songTime - daNote.strumTime) * (0.45 * PlayState.SONG.speed)); From 04d51bb6c00c98846493f1caf5a371047615b432 Mon Sep 17 00:00:00 2001 From: Detoria <44783518+theDetourist@users.noreply.github.com> Date: Thu, 25 Mar 2021 03:55:47 -0300 Subject: [PATCH 05/10] Quick fix for songs not ending Callback got deleted last patch, that's all. From d385c0a8657cd4e36e91854a5a6790cca6157d28 Mon Sep 17 00:00:00 2001 From: Detoria <44783518+theDetourist@users.noreply.github.com> Date: Thu, 25 Mar 2021 15:54:26 -0300 Subject: [PATCH 06/10] Fix for song not ending Just a callback that got deleted by mistake last patch. (also sorry for the confusion on the commits, I'm new to all this shit so) --- source/PlayState.hx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/PlayState.hx b/source/PlayState.hx index 0e4b495..3d725c2 100644 --- a/source/PlayState.hx +++ b/source/PlayState.hx @@ -1130,7 +1130,7 @@ class PlayState extends MusicBeatState lastReportedPlayheadPosition = 0; if (!paused) - FlxG.sound.playMusic(Paths.inst(PlayState.SONG.song), 1, false); + FlxG.sound.playMusic(Paths.inst(PlayState.SONG.song), 1, false); FlxG.sound.music.onComplete = endSong; vocals.play(); @@ -3027,4 +3027,4 @@ class PlayState extends MusicBeatState } var curLight:Int = 0; -} \ No newline at end of file +} From f16ceee837b689d114e8005334dde6e5497e377f Mon Sep 17 00:00:00 2001 From: Detoria <44783518+theDetourist@users.noreply.github.com> Date: Thu, 25 Mar 2021 15:58:14 -0300 Subject: [PATCH 07/10] Add Discord RPC to README --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index d8cf64a..5d3d165 100644 --- a/README.md +++ b/README.md @@ -106,6 +106,9 @@ You should have everything ready for compiling the game! Follow the guide below At the moment, you can optionally fix the transition bug in songs with zoomed out cameras. - Run `haxelib git flixel-addons https://github.com/HaxeFlixel/flixel-addons` in the terminal/command-prompt. +As of version 1.3, you also need Discord RPC to compile the game, get it by using the following command: +- Use `haxelib git discord_rpc https://github.com/Aidan63/linc_discord-rpc` in the terminal/command-prompt. + ### Ignored files I gitignore the API keys for the game, so that no one can nab them and post fake highscores on the leaderboards. But because of that the game From c239d05aa8d6cb1518b8535620e8416ad634fa8e Mon Sep 17 00:00:00 2001 From: Detoria <44783518+theDetourist@users.noreply.github.com> Date: Thu, 25 Mar 2021 15:58:38 -0300 Subject: [PATCH 08/10] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 5d3d165..9b52767 100644 --- a/README.md +++ b/README.md @@ -106,7 +106,7 @@ You should have everything ready for compiling the game! Follow the guide below At the moment, you can optionally fix the transition bug in songs with zoomed out cameras. - Run `haxelib git flixel-addons https://github.com/HaxeFlixel/flixel-addons` in the terminal/command-prompt. -As of version 1.3, you also need Discord RPC to compile the game, get it by using the following command: +**As of version 1.3**, you also need Discord RPC to compile the game, get it by using the following command: - Use `haxelib git discord_rpc https://github.com/Aidan63/linc_discord-rpc` in the terminal/command-prompt. ### Ignored files From 463269dbe497d82b14f70d5745869bfc74d3e8ee Mon Sep 17 00:00:00 2001 From: Detoria <44783518+theDetourist@users.noreply.github.com> Date: Thu, 25 Mar 2021 15:59:39 -0300 Subject: [PATCH 09/10] Update Note.hx --- source/Note.hx | 58 +++++++++++++++++--------------------------------- 1 file changed, 19 insertions(+), 39 deletions(-) diff --git a/source/Note.hx b/source/Note.hx index 88793ec..c7cde28 100644 --- a/source/Note.hx +++ b/source/Note.hx @@ -40,9 +40,8 @@ class Note extends FlxSprite if (prevNote == null) prevNote = this; - // And have up and down arrows flipped too? Nop - /* if (FlxG.save.data.downscroll) - flipY = true; */ + if (FlxG.save.data.downscroll) + flipY = true; this.prevNote = prevNote; isSustainNote = sustainNote; @@ -50,7 +49,6 @@ class Note extends FlxSprite x += 50; // MAKE SURE ITS DEFINITELY OFF SCREEN? y -= 2000; - this.strumTime = strumTime + FlxG.save.data.offset; this.noteData = noteData; @@ -66,30 +64,20 @@ class Note extends FlxSprite animation.add('redScroll', [7]); animation.add('blueScroll', [5]); animation.add('purpleScroll', [4]); - - // Hold piece - animation.add('purplehold', [0]); - animation.add('greenhold', [2]); - animation.add('redhold', [3]); - animation.add('bluehold', [1]); - + if (isSustainNote) { loadGraphic(Paths.image('weeb/pixelUI/arrowEnds'), true, 7, 6); - if(!FlxG.save.data.downscroll) - { - // Trail end - animation.add('purpleholdend', [4]); - animation.add('greenholdend', [6]); - animation.add('redholdend', [7]); - animation.add('blueholdend', [5]); - }else { - animation.add('purpleholdend', [4], 0, false, false, true); - animation.add('greenholdend', [6], 0, false, false, true); - animation.add('redholdend', [7], 0, false, false, true); - animation.add('blueholdend', [5], 0, false, false, true); - } + animation.add('purpleholdend', [4]); + animation.add('greenholdend', [6]); + animation.add('redholdend', [7]); + animation.add('blueholdend', [5]); + + animation.add('purplehold', [0]); + animation.add('greenhold', [2]); + animation.add('redhold', [3]); + animation.add('bluehold', [1]); } setGraphicSize(Std.int(width * PlayState.daPixelZoom)); @@ -102,24 +90,16 @@ class Note extends FlxSprite animation.addByPrefix('redScroll', 'red0'); animation.addByPrefix('blueScroll', 'blue0'); animation.addByPrefix('purpleScroll', 'purple0'); - + + animation.addByPrefix('purpleholdend', 'pruple end hold'); + animation.addByPrefix('greenholdend', 'green hold end'); + animation.addByPrefix('redholdend', 'red hold end'); + animation.addByPrefix('blueholdend', 'blue hold end'); + animation.addByPrefix('purplehold', 'purple hold piece'); animation.addByPrefix('greenhold', 'green hold piece'); animation.addByPrefix('redhold', 'red hold piece'); animation.addByPrefix('bluehold', 'blue hold piece'); - - if(!FlxG.save.data.downscroll) - { - animation.addByPrefix('purpleholdend', 'pruple end hold'); - animation.addByPrefix('greenholdend', 'green hold end'); - animation.addByPrefix('redholdend', 'red hold end'); - animation.addByPrefix('blueholdend', 'blue hold end'); - }else { - animation.addByPrefix('purpleholdend', 'pruple end hold', 0, false, false, true); - animation.addByPrefix('greenholdend', 'green hold end', 0, false, false, true); - animation.addByPrefix('redholdend', 'red hold end', 0, false, false, true); - animation.addByPrefix('blueholdend', 'blue hold end', 0, false, false, true); - } setGraphicSize(Std.int(width * 0.7)); updateHitbox(); @@ -184,7 +164,7 @@ class Note extends FlxSprite prevNote.animation.play('redhold'); } - prevNote.scale.y *= Conductor.stepCrochet / 100 * 1.5 * FlxG.save.data.noteSpeed; + prevNote.scale.y *= Conductor.stepCrochet / 100 * 1.5 * PlayState.SONG.speed; prevNote.updateHitbox(); // prevNote.setGraphicSize(); } From 1d091130ac73da68af97d7bfb9c86c0cc54c53fc Mon Sep 17 00:00:00 2001 From: Detoria <44783518+theDetourist@users.noreply.github.com> Date: Thu, 25 Mar 2021 16:00:17 -0300 Subject: [PATCH 10/10] Update OptionsMenu.hx --- source/OptionsMenu.hx | 80 ++++--------------------------------------- 1 file changed, 6 insertions(+), 74 deletions(-) diff --git a/source/OptionsMenu.hx b/source/OptionsMenu.hx index 1dea8a7..68ee6e7 100644 --- a/source/OptionsMenu.hx +++ b/source/OptionsMenu.hx @@ -17,8 +17,6 @@ class OptionsMenu extends MusicBeatState { var selector:FlxText; var curSelected:Int = 0; - var chartSpeed:FlxText; - var speedState:String; var controlsStrings:Array = []; @@ -33,7 +31,6 @@ class OptionsMenu extends MusicBeatState "\n" + (FlxG.save.data.downscroll ? 'Downscroll' : 'Upscroll') + "\nAccuracy " + (!FlxG.save.data.accuracyDisplay ? "off" : "on") + "\nSong Position " + (!FlxG.save.data.songPosition ? "off" : "on") + - "\nNote Speed" + "\nEtterna Mode " + (!FlxG.save.data.etternaMode ? "off" : "on") + "\nLoad replays"); @@ -64,20 +61,6 @@ class OptionsMenu extends MusicBeatState versionShit.setFormat("VCR OSD Mono", 16, FlxColor.WHITE, LEFT, FlxTextBorderStyle.OUTLINE, FlxColor.BLACK); add(versionShit); - var tmp_Speed:Float = FlxG.save.data.noteSpeed; - - chartSpeed = new FlxText(FlxG.width - 387, FlxG.height - 18, 0, "Note Speed (Hover, then Left and Right): " + tmp_Speed, 12); - chartSpeed.scrollFactor.set(); - chartSpeed.setFormat("VCR OSD Mono", 16, FlxColor.WHITE, LEFT, FlxTextBorderStyle.OUTLINE, FlxColor.BLACK); - - if(tmp_Speed == -1) chartSpeed.x = FlxG.width - 470; - else if(tmp_Speed == 1.5 || tmp_Speed == 2.5 || tmp_Speed == 3.5) chartSpeed.x = FlxG.width - 405; - else chartSpeed.x = FlxG.width - 387; - - if(FlxG.save.data.noteSpeed > 0) chartSpeed.text = "Note Speed (Hover, then Left and Right): " + FlxG.save.data.noteSpeed.toString(); - else chartSpeed.text = "Note Speed (Hover, then Left and Right): Song Based"; - add(chartSpeed); - super.create(); } @@ -94,72 +77,21 @@ class OptionsMenu extends MusicBeatState if (controls.RIGHT_R) { - if(curSelected != 5) - { - FlxG.save.data.offset++; - versionShit.text = "Offset (Left, Right): " + FlxG.save.data.offset; - }else { - if(FlxG.save.data.noteSpeed < 4.0) - if(FlxG.save.data.noteSpeed == -1) FlxG.save.data.noteSpeed = 1.0; - else FlxG.save.data.noteSpeed += 0.5; - - grpControls.remove(grpControls.members[curSelected]); - var ctrl:Alphabet = new Alphabet(0, (70 * curSelected) + 30, "Note Speed", true, false); - ctrl.isMenuItem = true; - ctrl.targetY = curSelected - 5; - grpControls.add(ctrl); - - if(FlxG.save.data.noteSpeed > 0) speedState = FlxG.save.data.noteSpeed.toString(); - else speedState = "Song Based"; - - chartSpeed.text = "Note Speed (Hover, then Left and Right): " + speedState; - - trace(FlxG.save.data.noteSpeed); - } + FlxG.save.data.offset++; + versionShit.text = "Offset (Left, Right): " + FlxG.save.data.offset; } if (controls.LEFT_R) - { - if(curSelected != 5) { FlxG.save.data.offset--; versionShit.text = "Offset (Left, Right): " + FlxG.save.data.offset; - }else { - if(FlxG.save.data.noteSpeed > 1.0) FlxG.save.data.noteSpeed -= 0.5; - else FlxG.save.data.noteSpeed = -1; - - trace(FlxG.save.data.noteSpeed); - var speedState = ""; - - if(FlxG.save.data.noteSpeed > 0) speedState = FlxG.save.data.noteSpeed.toString(); - else speedState = "Song Based"; - - chartSpeed.text = "Note Speed (Hover, then Left and Right): " + speedState; - - grpControls.remove(grpControls.members[curSelected]); - var ctrl:Alphabet = new Alphabet(0, (70 * curSelected) + 30, "Note Speed", true, false); - ctrl.isMenuItem = true; - ctrl.targetY = curSelected - 5; - grpControls.add(ctrl); - - trace(FlxG.save.data.noteSpeed); } - } - if(controls.LEFT_R && curSelected == 5 || controls.RIGHT_R && curSelected == 5 ) - { - var tmp_Speed:Float = FlxG.save.data.noteSpeed; - - if(tmp_Speed == -1) chartSpeed.x = FlxG.width - 470; - else if(tmp_Speed == 1.5 || tmp_Speed == 2.5 || tmp_Speed == 3.5) chartSpeed.x = FlxG.width - 405; - else chartSpeed.x = FlxG.width - 387; - } if (controls.ACCEPT) { - if (curSelected != 7 && curSelected != 5) + if (curSelected != 6) grpControls.remove(grpControls.members[curSelected]); - switch(curSelected) { case 0: @@ -197,13 +129,13 @@ class OptionsMenu extends MusicBeatState ctrl.isMenuItem = true; ctrl.targetY = curSelected - 4; grpControls.add(ctrl); - case 6: + case 5: FlxG.save.data.etternaMode = !FlxG.save.data.etternaMode; var ctrl:Alphabet = new Alphabet(0, (70 * curSelected) + 30, "Etterna Mode " + (!FlxG.save.data.etternaMode ? "off" : "on"), true, false); ctrl.isMenuItem = true; - ctrl.targetY = curSelected - 6; + ctrl.targetY = curSelected - 5; grpControls.add(ctrl); - case 7: + case 6: trace('switch'); FlxG.switchState(new LoadReplayState()); }