mirror of
https://github.com/holub/mame
synced 2025-07-02 08:39:21 +03:00
plugins/cheatfind: more (nw)
This commit is contained in:
parent
37898321e2
commit
295774fabb
@ -476,12 +476,10 @@ function cheatfind.startplugin()
|
|||||||
end
|
end
|
||||||
return m, function(event) local r bcd, r = incdec(event, bcd, 0, 1) return r end
|
return m, function(event) local r bcd, r = incdec(event, bcd, 0, 1) return r end
|
||||||
end
|
end
|
||||||
|
if #matches ~= 0 then
|
||||||
menu[#menu + 1] = function()
|
menu[#menu + 1] = function()
|
||||||
if #matches == 0 then
|
|
||||||
return nil
|
|
||||||
end
|
|
||||||
local function f(event)
|
local function f(event)
|
||||||
if event == "select" and #matches > 0 then
|
if event == "select" then
|
||||||
matches[#matches] = nil
|
matches[#matches] = nil
|
||||||
matchpg = 0
|
matchpg = 0
|
||||||
return true
|
return true
|
||||||
@ -489,7 +487,6 @@ function cheatfind.startplugin()
|
|||||||
end
|
end
|
||||||
return { "Undo last search -- #" .. #matches, "", 0 }, f
|
return { "Undo last search -- #" .. #matches, "", 0 }, f
|
||||||
end
|
end
|
||||||
if #matches ~= 0 then
|
|
||||||
menu[#menu + 1] = function() return { "---", "", "off" }, nil end
|
menu[#menu + 1] = function() return { "---", "", "off" }, nil end
|
||||||
menu[#menu + 1] = function()
|
menu[#menu + 1] = function()
|
||||||
local m = { "Match block", matchsel, "" }
|
local m = { "Match block", matchsel, "" }
|
||||||
@ -632,8 +629,7 @@ function cheatfind.startplugin()
|
|||||||
return m, f
|
return m, f
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
if matches[#matches].count > 100 then
|
||||||
if #matches > 0 and matches[#matches].count > 100 then
|
|
||||||
menu[#menu + 1] = function()
|
menu[#menu + 1] = function()
|
||||||
local m = { "Page", matchpg, 0 }
|
local m = { "Page", matchpg, 0 }
|
||||||
local max
|
local max
|
||||||
@ -650,6 +646,7 @@ function cheatfind.startplugin()
|
|||||||
return m, f
|
return m, f
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
if #watches ~= 0 then
|
if #watches ~= 0 then
|
||||||
menu[#menu + 1] = function()
|
menu[#menu + 1] = function()
|
||||||
return { "Clear Watches", "", 0 }, function(event) if event == "select" then watches = {} return true end end
|
return { "Clear Watches", "", 0 }, function(event) if event == "select" then watches = {} return true end end
|
||||||
|
Loading…
Reference in New Issue
Block a user