[Game]Anarch -- Doom clone FPS

Also isn’t there a C compiler for DOS that supports C99? If you have to change things anywhere in the h files it will be much more difficult.

1 Like

Yeah, I’m using double buffering, although I’m not blocking to sync with the vga card before I write the buffer to video memory.

I’ll try to upload the source soon. I’ll have to grab the files from the VM and make a git repo. I might make a repo with only the files needed for DOS so it’s actually easier to use there. For example, I had to rename some of the files so their names wouldn’t be truncated.

I just tried that, and it didn’t make a difference. The code makes it seem that 3 is the max size that would be allocated there anyway.

OpenWatcom has experimental C99 support (with an “undocumented” flag), and I was surprised to find that I only had to make a couple of small changes to the .h files.

FreeDOS seems to be a bit broken, and I had trouble actually using the compilers it says it comes with. Installing the packages doesn’t actually set any of the required path variables, and the OpenWatcom package wouldn’t extract unless I did it manually. I might try to get djgpp (a dos port of gcc) working now that I finally managed to get OpenWatcom to work. Maybe a change in compiler will be all it needs. I was hoping I wouldn’t have to go through the efforts of getting another compiler to work, though.

For better debugging you can try to compile the DOS version with all the changes you made on your primary OS.

I was wrong about this. I had made changes in two places, but I had only increased the limit in one. Tracking that bug down was quite the adventure, though. I actually got gdb working in FreeDOS, and check out what debugging is like when the system is still in 320x200 resolution:

VirtualBox_FreeDOS_21_03_2021_16_16_09

Anyway, I got it working. I also fixed the palette, and it’s working pretty well now (still no sound, no mouse, no saving):

I uploaded the source and binary as well:

3 Likes

For the record, the real hardware used in the video is an Intel Pentium 4 processor which is clocked at 1.3 GHz or higher, while original Doom could run smooth on an Intel 486 DX 66 MHz. Please correct me if I’m wrong.

I would test it on earlier hardware if I could. I might be able to try it on a Pentium II at some point, but I can’t test on anything older at the moment. It would be awesome if somebody with a 386 or 486 could try it out on those systems. It certainly is not so impressive that a Pentium 4 can run it smoothly, but my intention was to determine that the port would run natively in DOS.

1 Like

Niiice, thanks again for this port :slight_smile: I’ve added it to my README.

4 Likes

Anyone else curious if this could be upgraded to add Multiplayer for Pokitto+ ?!

3 Likes

Oh i am curious for sure!

1 Like

Indeed I’ve been thinking about multiplayer but currently I’m working on something else (simple 3D physics engine) and if I was to go for it, I’d like to officially add multiplayer in a nice multiplatform way so it would definitely take quite some effort. As a proof of concept for P+ it could be easier to first make a simpler shooter with raycastlib, e.g. based on that one raycastlib demo for Pokitto:

The code is much, much simpler and ofc you could still plug in some Anarch resources, e.g. the weapon and item sprites. Could be just this single map (could still be modified and recompiled any time), single level floor to avoid the hassle with shooting up/down.

9 Likes