I'm writing a small game in pure BASIC, and I want to save a hiscore file in the current directory when the game is loaded from disk. So how do I cleanly detect this under BASIC?
My idea was to use dskf(0), which should throw an error if the function call or disk isn't available. And this works fine with plain MSX BASIC, both on an emulator (tested BASIC 1.0 with and without Disk BASIC, and BASIC 2.0 with and without a floppy available) and on my SVI738 with BASIC 3.0. However, with my Carnivore 2 w. Nextor 2.10 installed it does not work correctly. Calling dskf(0) with the floppy as current drive and no disk inserted will reset the machine.
So am I misusing dskf, or is this a Nextor bug? Is there a better/more correct way to do this?
Entrar ou registrar-se para comentar