diff options
author | cracyc <cracyc@users.noreply.github.com> | 2016-04-17 17:38:16 -0500 |
---|---|---|
committer | cracyc <cracyc@users.noreply.github.com> | 2016-04-17 17:38:16 -0500 |
commit | b793232c972ac07923f6ed4389d0262ac91e6ed3 (patch) | |
tree | 67053e7018a521cd8ffcfd71e50e5bd63e1b8ca9 /plugins | |
parent | 73bf0b9521fa266fbbcfdf0116eea420753cb80b (diff) |
plugins/cheat: clear popmessage (nw)
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/cheat/init.lua | 1 | ||||
-rw-r--r-- | plugins/cheatfind/init.lua | 12 |
2 files changed, 8 insertions, 5 deletions
diff --git a/plugins/cheat/init.lua b/plugins/cheat/init.lua index ea6f4bba3fb..b77ee97fc46 100644 --- a/plugins/cheat/init.lua +++ b/plugins/cheat/init.lua @@ -327,6 +327,7 @@ function cheat.startplugin() end local function menu_callback(index, event) + manager:machine():popmessage() if index > #cheats and event == "select" then index = index - #cheats if index == 2 then diff --git a/plugins/cheatfind/init.lua b/plugins/cheatfind/init.lua index c72fc95edac..69fd9346800 100644 --- a/plugins/cheatfind/init.lua +++ b/plugins/cheatfind/init.lua @@ -243,8 +243,8 @@ function cheatfind.startplugin() matchsel = 1 menu_blocks = {} - table = cheat.getspaces() - for tag, list in pairs(table) do + local space_table = cheat.getspaces() + for tag, list in pairs(space_table) do if list.program then local ram = {} for num, entry in pairs(list.program.map) do @@ -257,8 +257,8 @@ function cheatfind.startplugin() end end end - table = cheat.getram() - for tag, ram in pairs(table) do + space_table = cheat.getram() + for tag, ram in pairs(space_table) do devtable[#devtable + 1] = { tag = tag, space = ram.dev, ram = {{ offset = 0, size = ram.size }} } end end @@ -484,10 +484,12 @@ function cheatfind.startplugin() _G.ce.inject(cheat) end else + local filename = string.format("%s_%08x_cheat.json", emu.romname(), match.addr) local json = require("json") - local file = io.open(string.format("%s_%08x_cheat.json", emu.romname(), match.addr), "w") + local file = io.open(filename, "w") file:write(json.stringify(cheat)) file:close() + manager:machine():popmessage("Cheat written to " .. filename) end end end |