• Paperboy GS emulation

    From Edward Armstrong@21:1/5 to All on Fri Feb 24 12:39:23 2023
    Did anyone ever get Paperboy GS to work on MAME or any of the KEGS-based emulators? The latter doesn't really get passed the title page, and in MAME, it crashes when certain sounds are triggered (like breaking glass). It feels like a sound or timing
    issue.

    I've tried all the copies floating around the net, plus I downloaded the Woz-a-day version, cracked it myself and tried it in KEGS and GSPlus, and still no joy. Any thoughts?

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From qkumba@21:1/5 to All on Fri Feb 24 17:36:36 2023
    I confirm that the sound timing is the issue in MAME. The game is waiting for the sound register to return a value in a specific range, which currently never occurs. I will see if I can work out why.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Kent Dickey@21:1/5 to peter.ferrie@gmail.com on Sun Feb 26 18:57:28 2023
    In article <c5a39a95-f2b6-429e-aeb7-38c53fb5d96fn@googlegroups.com>,
    qkumba <peter.ferrie@gmail.com> wrote:
    I confirm that the sound timing is the issue in MAME. The game is
    waiting for the sound register to return a value in a specific range,
    which currently never occurs. I will see if I can work out why.

    Ed Armstrong emailed me Feb 22 about KEGS not working, and it was an easy
    fix (for KEGS).

    Here's what I said:

    I looked into running it on KEGS. At the title screen, Paperboy is
    constantly reading the DOC last-sampled-played register, and is waiting
    for certain values to occur. As an optimization 25 years ago, KEGS only updates the DOC last-sample-played register at 60 times a second (to
    basically make it work for DOCVU, and things like it). And KEGS code
    had a comment saying this should be fixed.

    So I fixed it, and then it seems to play. I'm quite bad at the game,
    but I threw lots of papers, and even got 250 points eventually, and it
    didn't hang.

    I get the same results on the two .2MG files, and the .PO file. KEGS
    does not work with the .woz file, I'll need to look into that.

    If you want to patch KEGS.1.16 and see for yourself, modify sound.c at
    lines 1776-1779, and change it from:

    ---
    case 0x3: /* data register */
    /* HACK: make this call sound_play sometimes */
    g_doc_saved_val = rptr->last_samp_val;
    break;
    ---

    to

    ---
    case 0x3: /* data register */
    dsamps = dcycs * g_dsamps_per_dcyc;
    sound_play(dsamps);
    g_doc_saved_val = rptr->last_samp_val;
    break;
    ---

    Just add the "dsamps =" and sound_play() lines, and then recompile.

    You can probably make a similar patch to GSPort.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Edward Armstrong@21:1/5 to Kent Dickey on Mon Feb 27 12:37:22 2023
    On Sunday, February 26, 2023 at 1:57:30 PM UTC-5, Kent Dickey wrote:
    In article <c5a39a95-f2b6-429e...@googlegroups.com>,
    qkumba <peter....@gmail.com> wrote:
    I confirm that the sound timing is the issue in MAME. The game is
    waiting for the sound register to return a value in a specific range, >which currently never occurs. I will see if I can work out why.
    Ed Armstrong emailed me Feb 22 about KEGS not working, and it was an easy fix (for KEGS).

    Here's what I said:

    I looked into running it on KEGS. At the title screen, Paperboy is constantly reading the DOC last-sampled-played register, and is waiting
    for certain values to occur. As an optimization 25 years ago, KEGS only updates the DOC last-sample-played register at 60 times a second (to basically make it work for DOCVU, and things like it). And KEGS code
    had a comment saying this should be fixed.

    So I fixed it, and then it seems to play. I'm quite bad at the game,
    but I threw lots of papers, and even got 250 points eventually, and it didn't hang.

    I get the same results on the two .2MG files, and the .PO file. KEGS
    does not work with the .woz file, I'll need to look into that.

    If you want to patch KEGS.1.16 and see for yourself, modify sound.c at
    lines 1776-1779, and change it from:

    ---
    case 0x3: /* data register */
    /* HACK: make this call sound_play sometimes */
    g_doc_saved_val = rptr->last_samp_val;
    break;
    ---

    to

    ---
    case 0x3: /* data register */
    dsamps = dcycs * g_dsamps_per_dcyc;
    sound_play(dsamps);
    g_doc_saved_val = rptr->last_samp_val;
    break;
    ---

    Just add the "dsamps =" and sound_play() lines, and then recompile.

    You can probably make a similar patch to GSPort.

    Yes, can confirm that this fixes the issue. It also helps with some other titles as well (more on this later).

    Now we're just desperately trying to get a working exe on Windows and we'll be good!

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From qkumba@21:1/5 to All on Thu Mar 9 15:17:32 2023
    MAME was dropping the fractional part of the phase from the accumulator, so some parts of the sample weren't playing.
    I've proposed a fix which is waiting for approval or refinement.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)