Skip to content

Commit

Permalink
Updated plugins for Lua API changes coming in MAME 0.254
Browse files Browse the repository at this point in the history
  • Loading branch information
cuavas committed Apr 20, 2023
1 parent fad738b commit f666fa5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 2 additions & 1 deletion plugins/ksys573_da_offset/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ local exports = {

local plugindir

local stop_subscription

local function load_settings()
local json = require('json')
Expand Down Expand Up @@ -175,7 +176,7 @@ function ksys573_da_offset.startplugin()
emu.print_verbose(string.format('System 573 audio counter is now being offset by %s samples.', counter_offset))
end)

emu.register_stop(
stop_subscription = emu.add_machine_stop_notifier(
function ()
if passthrough_counter_high then
passthrough_counter_high:remove()
Expand Down
4 changes: 3 additions & 1 deletion plugins/viewswitch/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ local exports = {

local viewswitch = exports

local stop_subscription

function viewswitch.startplugin()
local switch_hotkeys = { }

Expand Down Expand Up @@ -71,7 +73,7 @@ function viewswitch.startplugin()

emu.register_frame_done(frame_done)
emu.register_prestart(start)
emu.register_stop(stop)
stop_subscription = emu.add_machine_stop_notifier(stop)
emu.register_menu(menu_callback, menu_populate, 'Quick View Switch')
end

Expand Down

0 comments on commit f666fa5

Please sign in to comment.