ADFFS 2.85

Floppy Disc Controller emulator and virtual IOC/IOMD/ARM JIT for modern RISC OS machines
JonAbbott
Posts: 3130
Joined: Thu Apr 11, 2013 12:13 pm
Location: Essex
Contact:

Re: ADFFS 2.85

Post by JonAbbott »

wmd wrote: Wed Jan 22, 2025 7:46 pm
JonAbbott wrote: Wed Jan 22, 2025 7:38 pmSome games just can't be run from HD, so there's no option but mount and boot the floppy - as in this case.
That's a shame, as high score saving is pretty important in this particular case.
It's a non-issue long-term as flushing will write back to the floppy image in real-time. Until flushing is implemented, the (full) floppy image is only written back when the floppy is dismounted - so a temporary workaround in your case might be to put a blank disc 2 image in the folder and just swap to disc 2 and then back to disc 1 and wait a while before rebooting or powering off.

If you imaged as a JFDm make sure your disc 1 floppy image is not write-protected and had the "Flush" flag set when you initially imaged it (just reimage if you're not sure). As this game doesn't use any complex protection, you can speed things up by imaging as an ADF.
wmd wrote: Wed Jan 22, 2025 7:46 pm Can the bit of code that saves to those two files not be adjusted to save to files outside the ADFFS (virtual?) environment?
The protection is multi-layered, with BASIC intermixed at various stages, so it's not possible to live-patch the individual games. At least three of the BASIC files have "$.x" hardcoded throughout it, so it's expecting to read/write from the root of the current filesystem.

There's no virtual environment on the machine you're playing it on, ADFFS is just acting as a floppy emulator. It's only on RiscPC and later that virtual environments come into effect when the JIT is used.
wmd
Posts: 167
Joined: Thu Feb 04, 2021 1:02 am

Re: ADFFS 2.85

Post by wmd »

JonAbbott wrote: Thu Jan 23, 2025 2:45 pma temporary workaround in your case might be to put a blank disc 2 image in the folder and just swap to disc 2 and then back to disc 1 and wait a while before rebooting or powering off.
This doesn't work - tried pressing Ctrl+F2, then Ctrl+F1 after a high score update. Notably, the egg timer does not appear as it usually would when switching discs.
JonAbbott wrote: Thu Jan 23, 2025 2:45 pmIf you imaged as a JFDm make sure your disc 1 floppy image is not write-protected and had the "Flush" flag set when you initially imaged it (just reimage if you're not sure).
Tried this, still no dice.
JonAbbott wrote: Thu Jan 23, 2025 2:45 pmAs this game doesn't use any complex protection, you can speed things up by imaging as an ADF.
Also tried this, and when booting the game from an ADF image, the screen goes black after selecting a game on the game selection screen.
JonAbbott
Posts: 3130
Joined: Thu Apr 11, 2013 12:13 pm
Location: Essex
Contact:

Re: ADFFS 2.85

Post by JonAbbott »

wmd wrote: Thu Jan 23, 2025 3:53 pm tried pressing Ctrl+F2, then Ctrl+F1 after a high score update. Notably, the egg timer does not appear as it usually would when switching discs.
It's CTRL-SHIFT-F1...F9 to swap floppies
wmd wrote: Thu Jan 23, 2025 3:53 pm
JonAbbott wrote: Thu Jan 23, 2025 2:45 pmAs this game doesn't use any complex protection, you can speed things up by imaging as an ADF.
Also tried this, and when booting the game from an ADF image, the screen goes black after selecting a game on the game selection screen.
That might be a bug in ADFFS, where the game is checking it was run via SHIFT-Break. I'll check the relevant code.

EDIT: It's only Zarkon Invasion that ends up on a blank screen. Which might be it's loader - I thought I'd fixed it, but will check.
wmd
Posts: 167
Joined: Thu Feb 04, 2021 1:02 am

Re: ADFFS 2.85

Post by wmd »

JonAbbott wrote: Thu Jan 23, 2025 6:36 pmIt's CTRL-SHIFT-F1...F9 to swap floppies
Tested this, scores still not saving.
JonAbbott
Posts: 3130
Joined: Thu Apr 11, 2013 12:13 pm
Location: Essex
Contact:

Re: ADFFS 2.85

Post by JonAbbott »

wmd wrote: Thu Jan 23, 2025 6:46 pm
JonAbbott wrote: Thu Jan 23, 2025 6:36 pmIt's CTRL-SHIFT-F1...F9 to swap floppies
Tested this, scores still not saving.
I've just tested. It appears CTRL-SHIFT-F1 is sufficient to write disc 1 back, so no 2nd disc image is required.

After getting a high score in Mazey, I immediately did a CTRL-SHIFT-F1 and then rebooted. On reloading it had my previous score, so why it's not working for you I can't explain.
wmd
Posts: 167
Joined: Thu Feb 04, 2021 1:02 am

Re: ADFFS 2.85

Post by wmd »

How did you get a high score? Did you zero the values in the high score files first (files 4 & 5)? When I zero those files in a hex editor, scores won't save using the method you describe. Or did you wipe the score files some other way?
JonAbbott
Posts: 3130
Joined: Thu Apr 11, 2013 12:13 pm
Location: Essex
Contact:

Re: ADFFS 2.85

Post by JonAbbott »

JonAbbott wrote: Thu Jan 23, 2025 6:36 pm It's only Zarkon Invasion that ends up on a blank screen. Which might be it's loader - I thought I'd fixed it, but will check.
Now this is interesting, as your physical floppy appears to have exactly the same corruption as the floppy I've imaged (it has bitrot). Without fixing it, Zarkon Invasion doesn't load.

Whilst investigating this, I did notice the ADF imager is clearing the end of the sector buffer after performing a DiscOp, instead of clearing it before - which is causing the corrupt sector mentioned above to not be saved to the ADF.
wmd wrote: Thu Jan 23, 2025 7:32 pm How did you get a high score? Did you zero the values in the high score files first (files 4 & 5)?
Yes, I just zero'd them.
wmd
Posts: 167
Joined: Thu Feb 04, 2021 1:02 am

Re: ADFFS 2.85

Post by wmd »

Yes, there's a lot of red blocks on the grid when I image from JFD to JFD. At first I thought it might have been part of the protection scheme. The disc / disc image you have is very likely the one I originally owned. Someone on the English Amiga Board imaged some of my Arc discs years ago (including that one), then I sold the original discs on ebay.

Would you mind uploading those zeroed score files please? It's possible I did it wrong when I changed my files.
JonAbbott
Posts: 3130
Joined: Thu Apr 11, 2013 12:13 pm
Location: Essex
Contact:

Re: ADFFS 2.85

Post by JonAbbott »

wmd wrote: Thu Jan 23, 2025 8:55 pm Yes, there's a lot of red blocks on the grid when I image from JFD to JFD.
I don't have an original to check, but I'm not expecting any red blocks if it's imaged from the original floppy. I'm expecting it to all be green.
ADFFS 2.85 doesn't currently include a recording file for it, so its imaging the full 800k. I've since created a recording file to reduce the image down to the files + protection, so its possible the original has unformatted tracks between the protection - unlikely, but possible. It would be unique if so.
wmd wrote: Thu Jan 23, 2025 8:55 pm The disc / disc image you have is very likely the one I originally owned.
I know where my archive copy originated from and it wasn't from yourself.
wmd wrote: Thu Jan 23, 2025 8:55 pm Would you mind uploading those zeroed score files please? It's possible I did it wrong when I changed my files.
I did this:

Code: Select all

FOR A%=&10000 TO &10100:?A%=0:NEXT
*SAVE ADFS::0.$.4 10000+BE
*SAVE ADFS::0.$.5 10000+BE
wmd
Posts: 167
Joined: Thu Feb 04, 2021 1:02 am

Re: ADFFS 2.85

Post by wmd »

JonAbbott wrote: Thu Jan 23, 2025 10:50 pmI don't have an original to check, but I'm not expecting any red blocks if it's imaged from the original floppy. I'm expecting it to all be green.
The person who imaged my original disc (many years ago) provided me with a adp file. When I image that to JFD I get this:

Image

All the games seem to work perfectly though.
JonAbbott wrote: Thu Jan 23, 2025 10:50 pmI know where my archive copy originated from and it wasn't from your copy.
Your youtube videos of this compilation have my name in the score tables.
JonAbbott wrote: Thu Jan 23, 2025 10:50 pm I did this:

Code: Select all

FOR A%=&10000 TO &10100:?A%=0:NEXT
*SAVE ADFS::0.$.4 10000+BE
*SAVE ADFS::0.$.5 10000+BE
Thanks, I will try this out.
Post Reply