diff --git a/scene/stick_config.lua b/scene/stick_config.lua index d39ba48..47362d7 100644 --- a/scene/stick_config.lua +++ b/scene/stick_config.lua @@ -72,14 +72,12 @@ function StickConfigScene:onInputPress(e) if e.type == "key" then -- function keys, escape, and tab are reserved and can't be remapped if e.scancode == "escape" or (self.input_state > #configurable_inputs and e.input == "menu_back") then - SCENE = InputConfigScene() + SCENE = InputConfigScene(SETTINGS.firstTime) elseif self.input_state > #configurable_inputs then - if e.scancode == "return" or e.input == "" then - -- save new input, then load next scene - local had_config = SETTINGS.input ~= nil - if not SETTINGS.input then SETTINGS.input = {} end - SETTINGS.input.joysticks = self.new_input - SCENE = had_config and InputConfigScene() or TitleScene() + if e.scancode == "return" or e.input == "menu_decide" then + SETTINGS.input.keys = self.new_input + SCENE = SETTINGS.firstTime and TitleScene() or InputConfigScene() + SETTINGS.firstTime = false elseif e.scancode == "delete" or e.scancode == "backspace" then -- retry self.input_state = 1