Hi, > On Jul 1, 2024, at 4:01 PM, Daniel Monteiro via Freedos-devel > <freedos-devel@lists.sourceforge.net> wrote: > > Answering both Bernd and Eric here. > > > Does the book cover more of these rather exotic instructions? Then perhaps > > this would be a nice reading for me too. > > There's a whole chapter called Advanced Instructions, detailing how to > achieve interesting results with some more "exotic" instructions. But > honestly, it's mostly the MOVs, PUSHs, ADDs and such. And that's fine - his > goal is to... > > > Do all games fit into a FAT boot sector, or at least in 1 sector? > > ... fit the games into 510 bytes, so it's bootable :) But it starts with .COM > files and later offers the option of building for both. Quite often, instead > of going for elegance or speed, size dictates his decisions. But damn, he > fits a mostly-complete chess on 510 bytes!
Similar, but different is my FDBANNER program. It is used the Floppy Edition at boot to display that text mode graphic “FreeDOS” banner that takes up about half the screen. The graphic is an 80 x 10 (800 pixels) image. It is a 3 color run-line encoded bitmap that was created with my ImgEdit program and exported as an assembly include for NASM. ImgEdit can export source code versions for Nasm, Pascal and C. The C version is an XBM include that I wrote but have never actually used or tested. So, that output filter may have issues. It also has it’s own format for graphics and animated sprites. Plus can Edit, Load and Save Bitmaps and fonts. The FDBANNER program has a simple decoder and includes the exported image. It compiles to 475 bytes. Looking at it know, I see a couple places I could easily shave a few more bytes out of the code. But, the goal was to fit the code and image in a single disk sector. 475 < 512 = time to move on. :-) > > > That sounds like a fun topic, which types of games does he cover? > > He goes over how the games are implemented. That's fine, but not exactly my > goal. I'm not going to use pure ASM, but rather try to have a minimal > "bootloader" to load my game from disk (mostly C, built with ia16-gcc). He > uses video memory as scratch memory, for instance. It's OK if you're > optimizing for that goal, but I want to build stuff with stronger resemblance > to modern software :P > > Also, in part, because I got spooked from a discussion we had back in 2022, > about some of my games having a double-press bug (turns out it was not with > my games, but I want to know what goes in the secret sauce). Oddly enough, I > had a flashback about this just yesterday, when I tried running some games > (mine and others) on my Macbook (2008, MB 4.1) and only the real mode stuff > was controllable. I wonder if this could result in a fork on this already > forked topic... > > Daniel > _______________________________________________ > Freedos-devel mailing list > Freedos-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/freedos-devel _______________________________________________ Freedos-devel mailing list Freedos-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/freedos-devel