diff --git a/assets/sounds/cancelMenu.mp3 b/assets/sounds/cancelMenu.mp3 new file mode 100644 index 000000000..c70e8cdb9 Binary files /dev/null and b/assets/sounds/cancelMenu.mp3 differ diff --git a/assets/sounds/cancelMenu.ogg b/assets/sounds/cancelMenu.ogg new file mode 100644 index 000000000..d56d11d40 Binary files /dev/null and b/assets/sounds/cancelMenu.ogg differ diff --git a/assets/sounds/confirmMenu.mp3 b/assets/sounds/confirmMenu.mp3 new file mode 100644 index 000000000..345797a80 Binary files /dev/null and b/assets/sounds/confirmMenu.mp3 differ diff --git a/assets/sounds/confirmMenu.ogg b/assets/sounds/confirmMenu.ogg new file mode 100644 index 000000000..f60010e4d Binary files /dev/null and b/assets/sounds/confirmMenu.ogg differ diff --git a/assets/sounds/scrollMenu.mp3 b/assets/sounds/scrollMenu.mp3 new file mode 100644 index 000000000..8a5e86645 Binary files /dev/null and b/assets/sounds/scrollMenu.mp3 differ diff --git a/assets/sounds/scrollMenu.ogg b/assets/sounds/scrollMenu.ogg new file mode 100644 index 000000000..e5697c93d Binary files /dev/null and b/assets/sounds/scrollMenu.ogg differ diff --git a/source/MainMenuState.hx b/source/MainMenuState.hx index 461ed982a..687f6191b 100644 --- a/source/MainMenuState.hx +++ b/source/MainMenuState.hx @@ -76,9 +76,21 @@ class MainMenuState extends MusicBeatState override function update(elapsed:Float) { if (controls.UP_P) + { + FlxG.sound.play('assets/sounds/scrollMenu' + TitleState.soundExt); changeItem(-1); + } + if (controls.DOWN_P) + { + FlxG.sound.play('assets/sounds/scrollMenu' + TitleState.soundExt); changeItem(1); + } + + if (controls.BACK) + { + FlxG.switchState(new TitleState()); + } super.update(elapsed); @@ -90,6 +102,8 @@ class MainMenuState extends MusicBeatState } else { + FlxG.sound.play('assets/sounds/confirmMenu' + TitleState.soundExt); + FlxFlicker.flicker(magenta, 1.1, 0.15, false); menuItems.forEach(function(spr:FlxSprite) diff --git a/source/StoryMenuState.hx b/source/StoryMenuState.hx index d583e0b07..e314eb7e2 100644 --- a/source/StoryMenuState.hx +++ b/source/StoryMenuState.hx @@ -161,17 +161,25 @@ class StoryMenuState extends MusicBeatState if (!selectedWeek) { if (controls.UP_P) + { changeWeek(-1); + } + if (controls.DOWN_P) + { changeWeek(1); + } } if (controls.ACCEPT) + { selectWeek(); + } } if (controls.BACK && !movedBack && !selectedWeek) { + FlxG.sound.play('assets/sounds/cancelMenu' + TitleState.soundExt); movedBack = true; FlxG.switchState(new MainMenuState()); } @@ -186,6 +194,8 @@ class StoryMenuState extends MusicBeatState { if (weekUnlocked[curWeek]) { + FlxG.sound.play('assets/sounds/confirmMenu' + TitleState.soundExt); + grpWeekText.members[curWeek].week.animation.resume(); grpWeekCharacters.members[1].animation.play('bfConfirm'); @@ -218,6 +228,8 @@ class StoryMenuState extends MusicBeatState bullShit++; } + FlxG.sound.play('assets/sounds/scrollMenu' + TitleState.soundExt); + updateText(); } diff --git a/source/TitleState.hx b/source/TitleState.hx index 835bfab22..5082c1215 100644 --- a/source/TitleState.hx +++ b/source/TitleState.hx @@ -73,13 +73,15 @@ class TitleState extends MusicBeatState FlxTransitionableState.defaultTransOut = new TransitionData(FADE, FlxColor.BLACK, 0.7, new FlxPoint(0, 1), {asset: diamond, width: 32, height: 32}, new FlxRect(0, 0, FlxG.width, FlxG.height)); - initialized = true; - FlxTransitionableState.defaultTransIn.tileData = {asset: diamond, width: 32, height: 32}; FlxTransitionableState.defaultTransOut.tileData = {asset: diamond, width: 32, height: 32}; transIn = FlxTransitionableState.defaultTransIn; transOut = FlxTransitionableState.defaultTransOut; + + FlxG.sound.playMusic('assets/music/freakyMenu' + TitleState.soundExt, 0); + + FlxG.sound.music.fadeIn(4, 0, 0.7); } persistentUpdate = true; @@ -126,11 +128,12 @@ class TitleState extends MusicBeatState FlxTween.tween(credTextShit, {y: credTextShit.y + 20}, 2.9, {ease: FlxEase.quadInOut, type: PINGPONG}); + if (initialized) + skipIntro(); + else + initialized = true; + // credGroup.add(credTextShit); - - FlxG.sound.playMusic('assets/music/freakyMenu' + TitleState.soundExt, 0); - - FlxG.sound.music.fadeIn(4, 0, 0.7); } var transitioning:Bool = false; @@ -149,14 +152,10 @@ class TitleState extends MusicBeatState pressedEnter = true; } - if (pressedEnter && !skippedIntro) - { - skipIntro(); - } - if (pressedEnter && !transitioning && skippedIntro) { FlxG.camera.flash(FlxColor.WHITE, 1); + FlxG.sound.play('assets/sounds/confirmMenu' + TitleState.soundExt, 0.7); transitioning = true; // FlxG.sound.music.stop(); @@ -168,6 +167,11 @@ class TitleState extends MusicBeatState // FlxG.sound.play('assets/music/titleShoot' + TitleState.soundExt, 0.7); } + if (pressedEnter && !skippedIntro) + { + skipIntro(); + } + super.update(elapsed); } @@ -265,6 +269,8 @@ class TitleState extends MusicBeatState { if (!skippedIntro) { + remove(ngSpr); + FlxG.camera.flash(FlxColor.WHITE, 4); remove(credGroup); skippedIntro = true;