Thursday, November 21, 2024 | Toby Opferman
 

Source Code - DOS



The software provided on this page is without warranty and provided "as is" for personal use. The user should use caution and run this software at their own risk. Resale or commerical use of these products is not permitted. The software on this page was written as practice and is provided here only as sample programs for those who may find them useful. While I will accept comments, bug reports and suggestions the software is considered legacy and is not under any on going development or support.

Simple Compiler
Year 2000
Language C
Operating System DOS
Simple Computer Language Compiler. I wrote this for a class. It's a simple language compiler. Recursive descent compiler. TEST.IN is a demo of what code for this language looks like. There is 1 thing missing, it's there is no way to assign a character literal, everything is string literals so if you make a character you won't be able to assign. This is just something I forgot and I don't feel like fixing it, this source is considered obsolete by me supporting anything in it. Also, there is a problem if you don't enter an input file and it prompts for one, the prompt is messed up that if you go to the end of the line and past, you can't backspace anymore. There's also some dead keyboard code that is not used. The download is big because it requires DOS4GW.EXE and the SCL exe included.


3D Wireframe Cube
Year 1998
Language Assembly
Operating System DOS
A 3D Rotating Cube on X, Y and Z axis. No Bounds checking so don't make it blow up off the screen. Scale it with +/-. Escape quits. Same program as under DEMOS, CUBE.COM, except this is the un-optimized version and is 1,173 bytes and not 899 bytes. This is a bit slower but they both rotate at a degree of 1.


Simple 3D Wire Frame Library
Year 1998
Language Assembly
Operating System DOS
Includes 3D.INC in which you can inlcude in your assembly programs to create & use Wire Frame 3D objects. Includes TEST3D.ASM sample on how to use 3D.INC. It supports World Coordinates, but not Camera Coordinates. No Bounds checking function, but you could easily add one to clip 2D Lines. Includes Rotation Functions, Line Drawing Function, 3D to 2D Projection Function, Scale Up/Down Functions and Draw Object Function.


Towers Of Hanoi
Year 1998
Language Prolog
Operating System DOS
Towers Of Hanoi game for Prolog interpreter. Originally it was used on a DOS-based interpreter however you should be able to use this on any prolog platform. This was done for a class. In case anyone finds it useful, I've provided the sources here.


Space Invaders
Year 1997
Language C/Assembly
Operating System DOS
Code to the DOS Space Invaders game under demos link. Compile and use the .PIC & .DAT files from that ZIP to run.


Random Number Generator
Year 1996
Language Assembly
Operating System DOS
A pseudo random number generator I wrote. I have commented the code extensively so it should be self explanatory!


Relative Program
Year 1996
Language LISP
Operating System DOS
A program I wrote for a LISP class. The class used a DOS-based LISP interpreter however any interpreter should be fine as there is nothing DOS specific. Majority of anyone doing LISP is likely also doing it for school work so I've provided this as a reference.


_Secret Demo
Year 1996
Language Assembly
Operating System DOS
This is the source to the _Secret demo, it includes 3 demo effects (Fire, Triangles and Snow). There is a bat file included which appends the fire color palette to the end of the build assembly .COM file.


Weird
Year 1995
Language C++
Operating System DOS
A C++ Program that demonstrates how to violate classes. Just a joke program, not recommended for real programming. It can be ported to other compilers, you just have to figure out if they have back doors. Mainly, how do they set up their memory when the program is compiled. (Turbo C++ 3.0)


 
About Toby Opferman

Professional software engineer with over 15 years...

Learn more »
Codeproject Articles

Programming related articles...

Articles »
Resume

Resume »
Contact

Email: codeproject(at)opferman(dot)com