mirror of
https://github.com/holub/mame
synced 2025-04-20 23:42:22 +03:00
plugins/hiscore: fix cpu tags and print detailed errors (nw)
This commit is contained in:
parent
5fa87ba20e
commit
031c9ca8fb
@ -2596,7 +2596,7 @@ bigrun:
|
||||
|
||||
;(scud hammer) (by GeoMan)
|
||||
scudhamm:
|
||||
@:cpu1,program,fd1ea,3c,00,01
|
||||
@:maincpu,program,fd1ea,3c,00,01
|
||||
|
||||
|
||||
;(cisco heat)
|
||||
@ -4606,7 +4606,7 @@ diverboy:
|
||||
djboy:
|
||||
djboya:
|
||||
djboyj:
|
||||
@:maincpu,program,b16a,2d,01,12
|
||||
@:mastercpu,program,b16a,2d,01,12
|
||||
|
||||
|
||||
;@s:dkong.cpp
|
||||
@ -5515,12 +5515,11 @@ mx5000:
|
||||
|
||||
;@s:flower.cpp
|
||||
|
||||
;*** flower / flower j not working - hiscore.dat parse error ??????? ***
|
||||
flower:
|
||||
flowerj:
|
||||
@:maincpu,program,d060,37,00,20
|
||||
@:maincpu,program,c00f,3,00,00
|
||||
@:maincpu,program,c010,1,30,30
|
||||
@:mastercpu,program,d060,37,00,20
|
||||
@:mastercpu,program,c00f,3,00,00
|
||||
@:mastercpu,program,c010,1,30,30
|
||||
|
||||
|
||||
;@s:flstory.cpp
|
||||
|
@ -63,8 +63,7 @@ function hiscore.startplugin()
|
||||
local cputag, space, offs, len, chk_st, chk_ed, fill = string.match(line, '^@([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),?(%x?%x?)');
|
||||
cpu = manager:machine().devices[cputag];
|
||||
if not cpu then
|
||||
emu.print_verbose("hiscore: " .. cputag .. " device not found")
|
||||
return nil
|
||||
error(cputag .. " device not found")
|
||||
end
|
||||
local rgnname, rgntype = space:match("([^/]*)/?([^/]*)")
|
||||
if rgntype == "share" then
|
||||
@ -73,8 +72,7 @@ function hiscore.startplugin()
|
||||
mem = cpu.spaces[space]
|
||||
end
|
||||
if not mem then
|
||||
emu.print_verbose("hiscore: " .. space .. " space not found")
|
||||
return nil;
|
||||
error(space .. " space not found")
|
||||
end
|
||||
_table[ #_table + 1 ] = {
|
||||
mem = mem,
|
||||
@ -278,9 +276,9 @@ function hiscore.startplugin()
|
||||
local dat = read_hiscore_dat()
|
||||
if dat and dat ~= "" then
|
||||
emu.print_verbose( "hiscore: found hiscore.dat entry for " .. emu.romname() );
|
||||
positions = parse_table( dat );
|
||||
if not positions then
|
||||
emu.print_error("hiscore: hiscore.dat parse error");
|
||||
res, positions = pcall(parse_table, dat);
|
||||
if not res then
|
||||
emu.print_error("hiscore: hiscore.dat parse error " .. positions);
|
||||
return;
|
||||
end
|
||||
for i, row in pairs(positions) do
|
||||
|
Loading…
Reference in New Issue
Block a user