]> 4ch.mooo.com Git - 16.git/blobdiff - src/scroll.c
same dos/cpu/vga probe for scroll.c
[16.git] / src / scroll.c
index d5222a50062e052506a742a3f1f3035753243d96..0c37c8c43f8a112902e171e216254e0f7a6fbdeb 100755 (executable)
@@ -64,6 +64,27 @@ void main(int argc, char *argv[])
        if(argv[1]) bakapee = atoi(argv[1]);
        else bakapee = 1;
 
+       // DOSLIB: check our environment
+       probe_dos();
+
+       // DOSLIB: what CPU are we using?
+       // NTS: I can see from the makefile Sparky4 intends this to run on 8088 by the -0 switch in CFLAGS.
+       //      So this code by itself shouldn't care too much what CPU it's running on. Except that other
+       //      parts of this project (DOSLIB itself) rely on CPU detection to know what is appropriate for
+       //      the CPU to carry out tasks. --J.C.
+       cpu_probe();
+
+       // DOSLIB: check for VGA
+       if (!probe_vga()) {
+               printf("VGA probe failed\n");
+               return;
+       }
+       // hardware must be VGA or higher!
+       if (!(vga_state.vga_flags & VGA_IS_VGA)) {
+               printf("This program requires VGA or higher graphics hardware\n");
+               return;
+       }
+
        testcontrolnoisy=0;
 
        player[0].persist_aniframe=0;