diff --git a/Project.xml b/Project.xml
index dcde8dc16..3eb374045 100644
--- a/Project.xml
+++ b/Project.xml
@@ -92,4 +92,5 @@
+
diff --git a/source/ButtonRemapSubstate.hx b/source/ButtonRemapSubstate.hx
new file mode 100644
index 000000000..64ff07948
--- /dev/null
+++ b/source/ButtonRemapSubstate.hx
@@ -0,0 +1,11 @@
+package;
+
+import flixel.FlxSubState;
+
+class ButtonRemapSubstate extends FlxSubState
+{
+ public function new()
+ {
+ super();
+ }
+}
diff --git a/source/FreeplayState.hx b/source/FreeplayState.hx
index 05b22123f..81366b3e1 100644
--- a/source/FreeplayState.hx
+++ b/source/FreeplayState.hx
@@ -40,11 +40,16 @@ class FreeplayState extends MusicBeatState
override function update(elapsed:Float)
{
- if (FlxG.keys.justPressed.UP)
+ super.update(elapsed);
+ var upP = controls.UP_P;
+ var downP = controls.DOWN_P;
+ var accepted = controls.ACCEPT;
+
+ if (upP)
{
curSelected -= 1;
}
- if (FlxG.keys.justPressed.DOWN)
+ if (downP)
{
curSelected += 1;
}
@@ -56,12 +61,10 @@ class FreeplayState extends MusicBeatState
selector.y = (70 * curSelected) + 30;
- if (FlxG.keys.justPressed.ENTER)
+ if (accepted)
{
PlayState.SONG = Song.loadFromJson(songs[curSelected].toLowerCase());
FlxG.switchState(new PlayState());
}
-
- super.update(elapsed);
}
}
diff --git a/source/Main.hx b/source/Main.hx
index e2e0f4dee..13376db44 100644
--- a/source/Main.hx
+++ b/source/Main.hx
@@ -9,7 +9,7 @@ class Main extends Sprite
public function new()
{
super();
- addChild(new FlxGame(0, 0, FreeplayState));
+ addChild(new FlxGame(0, 0, TitleState));
#if !mobile
addChild(new FPS(10, 3, 0xFFFFFF));
diff --git a/source/MusicBeatState.hx b/source/MusicBeatState.hx
index 321dc29c7..791cd95c7 100644
--- a/source/MusicBeatState.hx
+++ b/source/MusicBeatState.hx
@@ -15,6 +15,10 @@ class MusicBeatState extends FlxUIState
private var curStep:Int = 0;
private var curBeat:Int = 0;
+ private var controls(get, never):Controls;
+
+ inline function get_controls():Controls
+ return PlayerSettings.player1.controls;
override function create()
{
diff --git a/source/PlayState.hx b/source/PlayState.hx
index 10bf82f2c..e560db5ab 100644
--- a/source/PlayState.hx
+++ b/source/PlayState.hx
@@ -69,11 +69,6 @@ class PlayState extends MusicBeatState
private var camHUD:FlxCamera;
private var camGame:FlxCamera;
- var controls(get, never):Controls;
-
- inline function get_controls():Controls
- return PlayerSettings.player1.controls;
-
override public function create()
{
// var gameCam:FlxCamera = FlxG.camera;
@@ -86,8 +81,6 @@ class PlayState extends MusicBeatState
FlxCamera.defaultCameras = [camGame];
- PlayerSettings.init();
-
persistentUpdate = true;
persistentDraw = true;
@@ -1000,6 +993,7 @@ class PlayState extends MusicBeatState
combo = 0;
FlxG.sound.play('assets/sounds/missnote' + FlxG.random.int(1, 3) + TitleState.soundExt, FlxG.random.float(0.1, 0.2));
+ // FlxG.sound.play('assets/sounds/missnote1' + TitleState.soundExt, 1, false);
// FlxG.log.add('played imss note');
boyfriend.stunned = true;
@@ -1122,11 +1116,15 @@ class PlayState extends MusicBeatState
override function stepHit()
{
- if (vocals.time > Conductor.songPosition + Conductor.stepCrochet || vocals.time < Conductor.songPosition - Conductor.stepCrochet)
+ if (SONG.needsVoices)
{
- vocals.pause();
- vocals.time = Conductor.songPosition;
- vocals.play();
+ if (vocals.time > Conductor.songPosition + Conductor.stepCrochet
+ || vocals.time < Conductor.songPosition - Conductor.stepCrochet)
+ {
+ vocals.pause();
+ vocals.time = Conductor.songPosition;
+ vocals.play();
+ }
}
if (dad.curCharacter == 'spooky' && totalSteps % 4 == 2)
diff --git a/source/TitleState.hx b/source/TitleState.hx
index c1124ab4c..cf25c47fb 100644
--- a/source/TitleState.hx
+++ b/source/TitleState.hx
@@ -34,8 +34,21 @@ class TitleState extends MusicBeatState
TitleState.soundExt = '.ogg';
#end
+ PlayerSettings.init();
+
+ // DEBUG BULLSHIT
+
super.create();
+ #if SKIP_TO_PLAYSTATE
+ FlxG.switchState(new FreeplayState());
+ #else
+ startIntro();
+ #end
+ }
+
+ function startIntro()
+ {
if (!initialized)
{
var diamond:FlxGraphic = FlxGraphic.fromClass(GraphicTransTileDiamond);