diff options
Diffstat (limited to 'plugins/autofire/autofire_menu.lua')
-rw-r--r-- | plugins/autofire/autofire_menu.lua | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/plugins/autofire/autofire_menu.lua b/plugins/autofire/autofire_menu.lua index 4744de1b2ac..b9fb89d5042 100644 --- a/plugins/autofire/autofire_menu.lua +++ b/plugins/autofire/autofire_menu.lua @@ -76,6 +76,7 @@ end local function handle_main_menu(index, event, buttons) local section, adjusted_index = menu_section(index) if section == MENU_SECTIONS.CONTENT then + manager:machine():popmessage(_('Press UI Clear to delete')) if event == 'select' then current_button = buttons[adjusted_index] table.insert(menu_stack, MENU_TYPES.EDIT) @@ -108,10 +109,10 @@ end -- Borrowed from the cheat plugin local function poll_for_hotkey() local input = manager:machine():input() - local poller = input:sequence_poller() + local poller = input:switch_sequence_poller() manager:machine():popmessage(_('Press button for hotkey or wait to leave unchanged')) manager:machine():video():frame_update(true) - poller:start('switch') + poller:start() local time = os.clock() local clearmsg = true while (not poller:poll()) and (poller.modified or (os.clock() < time + 1)) do @@ -132,16 +133,16 @@ local function poll_for_hotkey() end local function handle_configure_menu(index, event) - -- Input if index == 1 then + -- Input if event == 'select' then table.insert(menu_stack, MENU_TYPES.BUTTON) return true else return false end - -- Hotkey elseif index == 2 then + -- Hotkey if event == 'select' then local keycode = poll_for_hotkey() if keycode then @@ -153,16 +154,16 @@ local function handle_configure_menu(index, event) else return false end - -- On frames elseif index == 3 then + -- On frames manager:machine():popmessage(_('Number of frames button will be pressed')) if event == 'left' then current_button.on_frames = current_button.on_frames - 1 elseif event == 'right' then current_button.on_frames = current_button.on_frames + 1 end - -- Off frames elseif index == 4 then + -- Off frames manager:machine():popmessage(_('Number of frames button will be released')) if event == 'left' then current_button.off_frames = current_button.off_frames - 1 |