summaryrefslogtreecommitdiffstatshomepage
path: root/plugins/cheat
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/cheat')
-rw-r--r--plugins/cheat/init.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/plugins/cheat/init.lua b/plugins/cheat/init.lua
index 10cda2d4cdd..418489f9525 100644
--- a/plugins/cheat/init.lua
+++ b/plugins/cheat/init.lua
@@ -569,7 +569,11 @@ function cheat.startplugin()
end
cheat.set_index = set_index;
cheat.set_value = function(cheat, value)
- local idx, chg = cheat:set_index((value / cheat.parameter.step) + 1)
+ local idx = (value / cheat.parameter.step) + 1
+ local chg = false
+ if math.integer(idx) == idx then
+ idx, chg = cheat:set_index(idx)
+ end
return cheat.parameter.value, chg
end
cheat.get_index = function(cheat) return cheat.parameter.index end
34d52964bf692889033ee7bfe1?s=128&d=retro' /> Miodrag Milanovic2011-02-241-1/+1 * Take advantage of the driver_device to clean up state saving for Aaron Giles2011-02-081-5/+5 * Attotime bulk conversion step: Aaron Giles2011-02-031-1/+1 * Ok, last major rename for this round: Aaron Giles2011-01-011-2/+2 * running_device -> device_t Aaron Giles2010-12-311-3/+3 * MDRV_* -> MCFG_* Aaron Giles2010-12-311-40/+40 * Changed the MACHINE_DRIVER_* macros, as follows: Aaron Giles2010-09-011-5/+2 * (Wow, I had no idea quite so many drivers were using driver_data!) Aaron Giles2010-08-041-10/+10 * Time to kill off some deadwood. Aaron Giles2010-07-071-7/+7 * Correct a long-standing design flaw: device configuration state Aaron Giles2010-01-181-3/+3 * Cleanups and version bump. Aaron Giles2010-01-161-1/+1 * Bulk driver.h -> emu.h switch. Aaron Giles2010-01-101-1/+1 * misc Konami wip: Fabio Priuli2010-01-051-77/+105 * Cleanups and version bump.mame0135u4 Aaron Giles2009-12-231-2/+2 * Updated ajax.c, bottom9.c, chqflag.c, rollerg.c, spy.c, surpratk.c to use Kon...