]> 4ch.mooo.com Git - 16.git/commitdiff
did some cleanings wwww
authorsparky4 <sparky4@cock.li>
Mon, 31 Oct 2016 15:36:54 +0000 (10:36 -0500)
committersparky4 <sparky4@cock.li>
Mon, 31 Oct 2016 15:36:54 +0000 (10:36 -0500)
50 files changed:
16/zcroll16.c [moved from src/lib/zcroll16.c with 100% similarity]
16/zcroll16.h [moved from src/lib/zcroll16.h with 96% similarity]
MEMINFO.16W [changed mode: 0644->0755]
cutetest.bat [changed mode: 0644->0755]
fmemtest.exe
fontgfx.exe
fonttest.exe
inputest.exe
makefile
maptest.exe
pcxtest.exe
pcxtest2.exe
q.sh [new file with mode: 0755]
src/16.h
src/exmmtest.c
src/fontgfx.c
src/inputest.c
src/lib/16_head.h
src/lib/16_in.c
src/lib/16_in.h
src/lib/16_map.c
src/lib/16_map.h
src/lib/16_mm.c
src/lib/16_pm.c
src/lib/16_timer.c
src/lib/16_vl.c [moved from src/lib/modex16.c with 96% similarity]
src/lib/16_vl.h [moved from src/lib/modex16.h with 92% similarity]
src/lib/16_vrs.h
src/lib/16render.h
src/lib/bakapee.h
src/lib/bitmap.c
src/lib/bitmap.h
src/lib/doslib
src/lib/mapread.c
src/lib/mapread.h
src/lib/modex16/16planar.h
src/lib/scroll16.h
src/palettec.c
src/palettel.c
src/pcxtest.c
src/pcxtest2.c
src/planrpcx.c
src/test.c
src/test2.c
src/tesuto.h
src/vgacamm.c
src/vrstest.c
test.exe
test0.exe
vgmtest.exe

similarity index 100%
rename from src/lib/zcroll16.c
rename to 16/zcroll16.c
similarity index 96%
rename from src/lib/zcroll16.h
rename to 16/zcroll16.h
index 6f66342967ca388e630e2d1528f6e1359c812541..ca730c232684357da36f425f214c23a4e2167b16 100755 (executable)
@@ -25,7 +25,7 @@
 \r
 #include "src/lib/16_head.h"\r
 //#include "src/lib/bakapee.h"\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 //#include "src/lib/16_in.h"\r
 #include "src/lib/bitmap.h"\r
 #include "src/lib/16_map.h" //map is loaded here www\r
@@ -93,7 +93,7 @@ extern unsigned char shinku_fps_indicator_page;
  * 1. Calculate, store and update a panning info, which includes, but not limited to:\r
  *     combined layer information, actual map representation (reflecting real state of the game),\r
  *     pixel shift for smooth tile scrolling.\r
- * 2. Provide ways to draw a visible part of map. For simplicity with smooth scrolling, \r
+ * 2. Provide ways to draw a visible part of map. For simplicity with smooth scrolling,\r
  *     additional row/column is always drawn at the each side of the map. This implies that 'fence'\r
  *     should have a sprite too. Map is drawn left-to-right, top-to-bottom.\r
  */\r
old mode 100644 (file)
new mode 100755 (executable)
old mode 100644 (file)
new mode 100755 (executable)
index ee3480f377f4944836f4bca9614676a13bc146fe..1dd10568a4713b5a38a2ee5dd083b50e8f3526e9 100755 (executable)
Binary files a/fmemtest.exe and b/fmemtest.exe differ
index d8891c5e1e3304cedd4cf550e122af5f770c506a..49b58b6541089846df3750f0bec102ffa2bfa3b9 100755 (executable)
Binary files a/fontgfx.exe and b/fontgfx.exe differ
index 22505eb088662aa3fafd7855b53380aa6aacac3e..99e247b8a89a6997c59481e248baa8697c7b7a54 100755 (executable)
Binary files a/fonttest.exe and b/fonttest.exe differ
index 0bc39164704a5a9b0f101c4573e5ae272c24e576..53a9bc31afeee8b7a81899dae1be2d9b0304d979 100755 (executable)
Binary files a/inputest.exe and b/inputest.exe differ
index 91da58cda59f12642dc738fc2dadd7bca1dc1a97..4582df3cc76dcea7fde2869b39826741bca61c00 100755 (executable)
--- a/makefile
+++ b/makefile
@@ -66,7 +66,7 @@ SRCLIB=src/lib
 JSMNLIB=src/lib/jsmn
 NYANLIB=src/lib/nyan
 EXMMLIB=src/lib/exmm
-MODEXLIB16=src/lib/modex16
+MODEXLIB16=src/lib/16_vl
 MODEXLIB=src/lib/modex
 VGMSNDLIB=src/lib/vgmsnd
 DOSLIB=src/lib/doslib
@@ -106,7 +106,8 @@ LIBFLAGS=$(WLIBQ) -b -n
 # objects
 #
 VGMSNDOBJ = vgmSnd.$(OBJ) 16_snd.$(OBJ)
-GFXLIBOBJS = modex16.$(OBJ) bitmap.$(OBJ) 16text.$(OBJ) bakapee.$(OBJ) scroll16.$(OBJ) 16render.$(OBJ) 16_vrs.$(OBJ) 16_sprit.$(OBJ)
+GFXLIBOBJS = 16_vl.$(OBJ) 16text.$(OBJ) bakapee.$(OBJ) scroll16.$(OBJ) 16render.$(OBJ) 16_vrs.$(OBJ) 16_sprit.$(OBJ)
+OLDGFXLIBOBJS=bitmap.$(OBJ)
 16LIBOBJS = 16_mm.$(OBJ) 16_pm.$(OBJ) 16_ca.$(OBJ) 16_tail.$(OBJ) 16_in.$(OBJ) 16_head.$(OBJ) 16_dbg.$(OBJ) kitten.$(OBJ) 16_hc.$(OBJ) wcpu.$(OBJ) 16_timer.$(OBJ)
 #16planar.$(OBJ) planar.$(OBJ)
 DOSLIBOBJ = adlib.$(OBJ) 8254.$(OBJ) 8259.$(OBJ) dos.$(OBJ) cpu.$(OBJ)
@@ -181,6 +182,7 @@ EXEC = &
     $(TESTEXEC)
 
 all: $(EXEC) joytest.exe
+testexec: $(EXEC) joytest.exe $(TESTEXEC2)
 
 #
 # game and bakapi executables
@@ -191,7 +193,7 @@ bakapi.exe:       bakapi.$(OBJ) gfx.lib $(DOSLIBLIBS)
 #
 # Test Executables!
 #
-scroll.exe:       scroll.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib $(DOSLIBLIBS)
+scroll.exe:       scroll.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib $(DOSLIBLIBS) $(OLDGFXLIBOBJS)
 scroll.$(OBJ):    $(SRC)/scroll.c
 zcroll.exe:       zcroll.$(OBJ) mapread.$(OBJ) jsmn.$(OBJ) $(16LIB) gfx.lib $(DOSLIBLIBS)
 zcroll.$(OBJ):    $(SRC)/zcroll.c
@@ -207,12 +209,12 @@ fonttest.exe:     fonttest.$(OBJ) gfx.lib
 fontgfx.exe:      fontgfx.$(OBJ) gfx.lib $(DOSLIBLIBS)
 inputest.exe:     inputest.$(OBJ) $(16LIB) $(DOSLIBLIBS)
 #sountest.exe:    sountest.$(OBJ) $(16LIB)
-pcxtest.exe:      pcxtest.$(OBJ) gfx.lib $(DOSLIBLIBS)
+pcxtest.exe:      pcxtest.$(OBJ) gfx.lib $(DOSLIBLIBS) $(OLDGFXLIBOBJS)
 vrstest.exe:      vrstest.$(OBJ) $(16LIB) gfx.lib $(DOSLIBLIBS)
 #vgacamm.exe:      vgacamm.$(OBJ) $(16LIB) gfx.lib $(DOSLIBLIBS)
 palettec.exe:     palettec.$(OBJ) gfx.lib $(DOSLIBLIBS)
 palettel.exe:     palettel.$(OBJ) gfx.lib $(DOSLIBLIBS)
-pcxtest2.exe:     pcxtest2.$(OBJ) gfx.lib $(DOSLIBLIBS)
+pcxtest2.exe:     pcxtest2.$(OBJ) gfx.lib $(DOSLIBLIBS) $(OLDGFXLIBOBJS)
 #planrpcx.exe:    planrpcx.$(OBJ) gfx.lib
 maptest.exe:      maptest.$(OBJ) 16_map.$(OBJ) 16_head.$(OBJ) jsmn.$(OBJ) gfx.lib $(DOSLIBLIBS)
 fmemtest.exe:     fmemtest.$(OBJ)
@@ -224,17 +226,17 @@ vgmtest.exe:      vgmtest.$(OBJ) vgmsnd.lib $(16LIB) $(DOSLIBLIBS)
 #
 16.$(OBJ):        $(SRC)/16.c $(SRC)/16.h
 bakapi.$(OBJ):    $(SRC)/bakapi.c $(SRC)/bakapi.h
-test.$(OBJ):      $(SRC)/test.c $(SRCLIB)/modex16.h
-#test2.$(OBJ):    $(SRC)/test2.c $(SRCLIB)/modex16.h
+test.$(OBJ):      $(SRC)/test.c $(SRCLIB)/16_vl.h
+#test2.$(OBJ):    $(SRC)/test2.c $(SRCLIB)/16_vl.h
 test0.$(OBJ):     $(SRC)/test0.c
-pcxtest.$(OBJ):   $(SRC)/pcxtest.c $(SRCLIB)/modex16.h
-vrstest.$(OBJ):   $(SRC)/vrstest.c $(SRCLIB)/modex16.h
-#vgacamm.$(OBJ):   $(SRC)/vgacamm.c $(SRCLIB)/modex16.h
-#planrpcx.$(OBJ): $(SRC)/planrpcx.c $(SRCLIB)/modex16.h
-pcxtest2.$(OBJ):  $(SRC)/pcxtest2.c $(SRCLIB)/modex16.h
+pcxtest.$(OBJ):   $(SRC)/pcxtest.c $(SRCLIB)/16_vl.h
+vrstest.$(OBJ):   $(SRC)/vrstest.c $(SRCLIB)/16_vl.h
+#vgacamm.$(OBJ):   $(SRC)/vgacamm.c $(SRCLIB)/16_vl.h
+#planrpcx.$(OBJ): $(SRC)/planrpcx.c $(SRCLIB)/16_vl.h
+pcxtest2.$(OBJ):  $(SRC)/pcxtest2.c $(SRCLIB)/16_vl.h
 palettec.$(OBJ):  $(SRC)/palettec.c
 palettel.$(OBJ):  $(SRC)/palettel.c
-maptest.$(OBJ):   $(SRC)/maptest.c $(SRCLIB)/modex16.h
+maptest.$(OBJ):   $(SRC)/maptest.c $(SRCLIB)/16_vl.h
 #emmtest.$(OBJ):  $(SRC)/emmtest.c
 #emsdump.$(OBJ):  $(SRC)/emsdump.c
 fmemtest.$(OBJ):  $(SRC)/fmemtest.c
@@ -278,7 +280,7 @@ joytest.exe:
        cd $(DOSLIB_JOYSTICK:$(to_os_path)) && $(DOSLIBMAKE) && cd $(BUILD_ROOT)
        $(COPYCOMMAND) $(DOSLIB_JOYSTICK:$(to_os_path))$(DIRSEP)dos86h$(DIRSEP)test.exe joytest.exe
 
-modex16.$(OBJ):   $(SRCLIB)/modex16.c $(SRCLIB)/modex16.h
+16_vl.$(OBJ):   $(SRCLIB)/16_vl.c $(SRCLIB)/16_vl.h
 bakapee.$(OBJ):   $(SRCLIB)/bakapee.c $(SRCLIB)/bakapee.h
 16render.$(OBJ):  $(SRCLIB)/16render.c $(SRCLIB)/16render.h
 16planar.$(OBJ):  $(MODEXLIB16)/16planar.c $(MODEXLIB16)/16planar.h
index e8e04a6334c12c6029476bcdd34538c249171006..e387020e13be95fb4c16c586280a10056b7a0991 100755 (executable)
Binary files a/maptest.exe and b/maptest.exe differ
index 9f5b82174631569b519c3e0442bf0c97aaede4b1..5febf45293dfeda02f70d9cafecc76f9aab9516c 100755 (executable)
Binary files a/pcxtest.exe and b/pcxtest.exe differ
index ef3287a22a56c19090d4ebbee191a85eddfa4250..caffd3da7ada24a40a0d33f61dc25a6750775299 100755 (executable)
Binary files a/pcxtest2.exe and b/pcxtest2.exe differ
diff --git a/q.sh b/q.sh
new file mode 100755 (executable)
index 0000000..db78af5
--- /dev/null
+++ b/q.sh
@@ -0,0 +1 @@
+grep -iR "$1" src/*
index 7f792bbb53601129973ca8d5db93aea447649d17..958a8e392f5abb150642d11a985dc7bf9d098932 100755 (executable)
--- a/src/16.h
+++ b/src/16.h
@@ -25,7 +25,7 @@
 \r
 #include "src/lib/16_head.h"\r
 #include "src/lib/16_in.h"\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/wcpu/wcpu.h"\r
 //#include "src/lib/planar.h"\r
 #include "src/lib/scroll16.h"\r
index f68d148e99bb4e1e2bff099a8cf7d50a796f985d..fc4eb11d61660c75a2d99dc86e7ebe282a03dc68 100755 (executable)
@@ -28,7 +28,7 @@
 #include "src/lib/16_ca.h"\r
 #include "src/lib/16_mm.h"\r
 #include "src/lib/16_hc.h"\r
-//#include "src/lib/modex16.h"\r
+//#include "src/lib/16_vl.h"\r
 #pragma hdrstop\r
 \r
 #pragma warn -pro\r
@@ -69,9 +69,9 @@ main(int argc, char *argv[])
 {\r
        byte w=1;\r
        static global_game_variables_t gvar;\r
-#ifdef __WATCOMC__\r
-       __segment sega;\r
-#endif\r
+//#ifdef __WATCOMC__\r
+//     __segment sega;\r
+//#endif\r
        memptr bigbuffer;\r
 \r
        //static byte bakapee[64];\r
@@ -133,9 +133,9 @@ for(w=0;w<2;w++)
        }\r
 //     close(bakapeehandle);\r
        //hmm functions in cache system use the buffered stuff\r
-#ifdef __WATCOMC__\r
-       printf("\nsize of big buffer~=%u\n", _bmsize(sega, bigbuffer));\r
-#endif\r
+//#ifdef __WATCOMC__\r
+//     printf("\nsize of big buffer~=%u\n", _bmsize(sega, bigbuffer));\r
+//#endif\r
 \r
        printf("contents of the buffer\n[\n%s\n]\n", bigbuffer);\r
        //printf("dark purple = purgable\n");\r
index 354a897bf5bdab0ee7bead1886db0717071975ea..e25a130a07f1e0c22e46559f4af06dcf1af91ca9 100755 (executable)
@@ -21,9 +21,9 @@
  */\r
 #include <stdio.h>\r
 #include <conio.h>\r
-#include "lib/types.h"\r
+#include "src/lib/types.h"\r
 //#include "lib/16text.h"\r
-#include "lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 \r
 #include <hw/cpu/cpu.h>\r
 #include <hw/dos/dos.h>\r
index be6ac4a2a725284c1f958afa1ada71b7fd4b86e5..a573d54a8e769cf0d86fde5781dd2506a723f3a9 100755 (executable)
@@ -30,7 +30,7 @@ main(int argc, char *argv[])
        global_game_variables_t gvar;\r
        player_t player[MaxPlayers];\r
        //extern struct inconfig inpu;\r
-       dbg_testkeyin=0;\r
+       dbg_testkeyin=1;\r
        dbg_testcontrolnoisy=1;\r
        IN_Startup();\r
        IN_Default(0,&player,ctrl_Joystick1);\r
index 6b189d875fcd864c0cb1107332c937739a47bd27..ef63aaf33a91d35d9cf3cf83e63cd8ce110f989b 100755 (executable)
 #define KEY_MENU               (0x75)\r
 */\r
 \r
-static word far* clockw= (word far*) 0x046C; /* 18.2hz clock */\r
+//static word far* clockw= (word far*) 0x046C; /* 18.2hz clock */\r
 extern int                     profilehandle,debughandle;      //make it into game global\r
 \r
 #define __DEBUG__\r
 //#define __DEBUG_PM__\r
 //#define __DEBUG_MM__\r
 \r
+//#define OLD16_VL\r
+\r
 #define        nil     ((void *)0)\r
 #ifdef __BORLANDC__\r
 #define _FCORELEFT 0x90000UL-16UL\r
@@ -169,7 +171,7 @@ extern      int                     profilehandle,debughandle;      //make it into game global
 #endif\r
 #ifdef __WATCOMC__\r
 #define _FCORELEFT 0x90000UL+16UL\r
-static union REGS CPURegs;\r
+/*static union REGS CPURegs;\r
 \r
 #define _AX CPURegs.x.ax\r
 #define _BX CPURegs.x.bx\r
@@ -187,7 +189,7 @@ static union REGS CPURegs;
 #define _DH CPURegs.h.dh\r
 #define _DL CPURegs.h.dl\r
 \r
-#define geninterrupt(n) int86(n,&CPURegs,&CPURegs);\r
+#define geninterrupt(n) int86(n,&CPURegs,&CPURegs);*/\r
 #define peekb(segm,ofs) (*(byte far*)MK_FP((segm),(ofs)))\r
 #define peekw(segm,ofs) (*(word far*)MK_FP((segm),(ofs)))\r
 #define pokeb(segm,ofs,value) (peekb((segm),(ofs)) = (byte)(value))\r
index 85709c5e00c53fc90dd649a8698984b3741005ba..0851baa9dd2e4b75315da6df584831b5ac335e2a 100755 (executable)
@@ -42,6 +42,8 @@
 boolean dbg_testkeyin=0,dbg_testcontrolnoisy=0;\r
 #endif\r
 \r
+static word far* clockw= (word far*) 0x046C; /* 18.2hz clock */\r
+\r
 /*\r
 =============================================================================\r
 \r
index 29ecc130e1f91616bf870bd9f88a895c6ea30f90..eb1650e46cbcbe3bcc6d309caa6c27eb07119389 100755 (executable)
@@ -33,7 +33,7 @@
 #ifdef __WATCOMC__     //borland C BCEXMM.EXE\r
 #include "src/lib/16_dbg.h"\r
 #include "src/lib/16_sprit.h"\r
-#include "src/lib/bitmap.h"    //old format\r
+//#include "src/lib/bitmap.h"  //old format\r
 #endif\r
 #ifdef __DEBUG__\r
 #define        __DEBUG_InputMgr__\r
index d697142d34a940f639141a717857513451fb60b9..c3d66e2c6e2ef80573244884cb7cc8ee38333e86 100755 (executable)
@@ -84,7 +84,7 @@ void extract_map(const char *js, jsmntok_t *t, size_t count, map_t *map) {
                                        map->tiles[k]->debug_text=false;\r
                                        //Fix to load tileset specified.\r
                                        //And move to vrs, probably\r
-                                       bp = bitmapLoadPcx("data/ed.pcx");\r
+                                       //bp = bitmapLoadPcx("data/ed.pcx");\r
                                        map->tiles[k]->btdata = &bp;\r
                                        k++;\r
                                }\r
@@ -151,6 +151,6 @@ int loadmap(char *mn, map_t *map) {
        free(js);\r
        free(tok);\r
        fclose(fh);\r
-       \r
+\r
        return 0;\r
 }\r
index cd3f934973e594404de32fdfa41701b8ec782d10..0642d2b4f2a1a2392959535e8fc92ead4b164496 100755 (executable)
@@ -26,7 +26,7 @@
 #include "jsmn/jsmn.h"\r
 //#include "stdio.h" included in 16_head.h\r
 //#include "stdlib.h" included in 16_head.h\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/16_head.h"\r
 #include "src/lib/16_ca.h"\r
 #include "src/lib/16_mm.h"\r
index 42a87440485b974a3b11baf23fb91f8c5119db73..c26363357c7043ab1919966c5882f4fa3ec6b17b 100755 (executable)
@@ -770,9 +770,7 @@ void MM_Startup(global_game_variables_t *gvar)
        gvar->mm.mmhead = NULL;
        gvar->mm.mmfree = &(gvar->mm.mmblocks[0]);
        for(i=0;i<MAXBLOCKS-1;i++)
-       {
                gvar->mm.mmblocks[i].next = &(gvar->mm.mmblocks[i+1]);
-       }
        gvar->mm.mmblocks[i].next = NULL;
 
 //
index c9019b785e70d5dccfc76fdd6d50ab5c713b8a04..ac61e20d70a38b7bf156249a919ebaf226f7f4d3 100755 (executable)
@@ -70,6 +70,26 @@ boolean dbg_debugpm=0;
        PageListStruct  far *gvar->pm.PMPages,\r
                                        _seg *gvar->pm.PMSegPages;*/\r
 \r
+static union REGS CPURegs;\r
+\r
+#define _AX CPURegs.x.ax\r
+#define _BX CPURegs.x.bx\r
+#define _CX CPURegs.x.cx\r
+#define _DX CPURegs.x.dx\r
+\r
+#define _SI CPURegs.x.si\r
+\r
+#define _AH CPURegs.h.ah\r
+#define _AL CPURegs.h.al\r
+#define _BH CPURegs.h.bh\r
+#define _BL CPURegs.h.bl\r
+#define _CH CPURegs.h.ch\r
+#define _CL CPURegs.h.cl\r
+#define _DH CPURegs.h.dh\r
+#define _DL CPURegs.h.dl\r
+\r
+#define geninterrupt(n) int86(n,&CPURegs,&CPURegs);\r
+\r
 static char            *ParmStrings[] = {"nomain","noems","noxms",nil};\r
 \r
 /////////////////////////////////////////////////////////////////////////////\r
index 4ce497099cebb25424d5e575c92120a89313299f..5cb216c19b48f47ce61eff49b157f55e9c382636 100755 (executable)
@@ -22,6 +22,8 @@
 \r
 #include "src/lib/16_timer.h"\r
 \r
+static word far* clockw= (word far*) 0x046C; /* 18.2hz clock */\r
+\r
 clock_t start_timer(global_game_variables_t *gv)\r
 {\r
        gv->kurokku.t = clock();\r
similarity index 96%
rename from src/lib/modex16.c
rename to src/lib/16_vl.c
index b8f733be22b581f1748cffffa04e1f60e988b3be..503cad0665a55fae3f4c8548e003d44ced52bccd 100755 (executable)
@@ -23,7 +23,7 @@
 #include <conio.h>\r
 #include <stdio.h>\r
 #include <stdlib.h>\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 \r
 byte far* VGA=(byte far*) 0xA0000000;   /* this points to video memory. */\r
 \r
similarity index 92%
rename from src/lib/modex16.h
rename to src/lib/16_vl.h
index 3467a77dd3487169751b90b5ad516b025c6d8b26..37eab24a6fa4579884701b4b37dfce6ed3c01037 100755 (executable)
 #include <hw/vga/vrs.h>\r
 #endif\r
 \r
-static struct pcxHeader {\r
-       byte id;\r
-       byte version;\r
-       byte encoding;\r
-       byte bpp;\r
-       word xmin;\r
-       word ymin;\r
-       word xmax;\r
-       word ymax;\r
-       word hres;\r
-       word vres;\r
-       byte pal16[48];\r
-       byte res1;\r
-       word bpplane;\r
-       word palType;\r
-       word hScreenSize;\r
-       word vScreenSize;\r
-       byte padding[54];\r
-} head;\r
-\r
 //320x240 = 20x15\r
 //192x144 = 12x9\r
 \r
index cdeb81a0cf74a1cdfa97abff15bacb9c76857419..9aceda0a8a3c3d633b34e3f69fbac14fc617cd38 100755 (executable)
@@ -22,7 +22,7 @@
 #ifndef __16_VRS__\r
 #define __16_VRS__\r
 \r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/typdefst.h"\r
 //#include <hw/cpu/cpu.h>\r
 //#include <hw/dos/dos.h>\r
index 9edce93799795e82ddbf7d7be7d9cb3de29a19d2..de842416a943356fded8d170b131d2bf145dccbc 100755 (executable)
@@ -23,7 +23,7 @@
 #ifndef __RENDER_H__\r
 #define __RENDER_H__\r
 \r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 \r
 void modexDrawPBufRegion(page_t *page, int x, int y, int rx, int ry, int rw, int rh, planar_buf_t *p, boolean sprite);\r
 void modexDrawPBuf(page_t *page, int x, int y, planar_buf_t *p, boolean sprite); /*temp*/\r
index 7ae770a10e5e92f30d79230a2598a2b0ab7e1ed5..4d3df42ce3d321cc8dd45cd08751cebe1b3722c3 100755 (executable)
@@ -45,7 +45,7 @@
  *\r
  */\r
 #include "src/lib/16_head.h"\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include <hw/cpu/cpu.h>\r
 #include <hw/dos/dos.h>\r
 #include <hw/vga/vga.h>\r
index 7696cc3475ed303e89dd5014f84ab1c4a7e4e626..1e4a8d5b54ea9b179b17566f3b92aec3db4e8e29 100755 (executable)
 #include <malloc.h>\r
 #include "src/lib/bitmap.h"\r
 \r
+static struct pcxHeader {\r
+       byte id;\r
+       byte version;\r
+       byte encoding;\r
+       byte bpp;\r
+       word xmin;\r
+       word ymin;\r
+       word xmax;\r
+       word ymax;\r
+       word hres;\r
+       word vres;\r
+       byte pal16[48];\r
+       byte res1;\r
+       word bpplane;\r
+       word palType;\r
+       word hScreenSize;\r
+       word vScreenSize;\r
+       byte padding[54];\r
+} head;\r
+\r
 static void loadPcxStage1(FILE *file, bitmap_t *result) {\r
        long bufSize;\r
        int index;\r
index 1d0154b15b399ae9437727ea6fcbd05eb6d8c9f0..6ef0af717d09818d4f06f5895557dcbd0863f146 100755 (executable)
@@ -26,7 +26,7 @@
 #ifndef BITMAP_H\r
 #define BITMAP_H\r
 \r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 \r
 bitmap_t bitmapLoadPcx(char *filename);\r
 tileset_t bitmapLoadPcxTiles(char *filename, word twidth, word theight);\r
index 979eddc7c8c7b92b6905d147c242ef7ea055d847..0ee1f206b4a2591ecfeca688c070a354e2ac0249 160000 (submodule)
@@ -1 +1 @@
-Subproject commit 979eddc7c8c7b92b6905d147c242ef7ea055d847
+Subproject commit 0ee1f206b4a2591ecfeca688c070a354e2ac0249
index 5421d9dd8a57cf37a23cbdc42006859b24117b06..039e0a01d1121ea2ae7cb63398f36eef3188d907 100755 (executable)
@@ -95,7 +95,7 @@ word dump(const char *js, jsmntok_t *t, size_t count, word indent, char *js_sv,
                        map->tiles = malloc(sizeof(tiles_t));\r
                        map->tiles->btdata = malloc(sizeof(bitmap_t));\r
                        //fix this to be far~\r
-                       bp = bitmapLoadPcx("data/ed.pcx");\r
+//0000                 bp = bitmapLoadPcx("data/ed.pcx");\r
 //                     bp = bitmapLoadPcx("data/koishi^^.pcx");\r
                        map->tiles->btdata = &bp;\r
 //----                 map->tiles->data = planar_buf_from_bitmap(&bp);\r
index d3c26c03ff207407212a1f28d1de7d36265f8fc7..88cc79ef43d98a84e00e4b0d5853973ce7c375c1 100755 (executable)
@@ -24,7 +24,7 @@
 #define _LIBMAPREAD_H_\r
 \r
 #include "src/lib/jsmn/jsmn.h"\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/16_head.h"\r
 \r
 //#define DEBUG_MAPDATA\r
index 2ff43e4616a068a3f3e62ed173881154247948ee..8084f70a1b7a97d17747f1ecd8d4637af1e6aa6f 100755 (executable)
@@ -28,7 +28,7 @@
 #ifndef PLANW_H\r
 #define PLANW_H\r
 \r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 \r
 planar_buf_t planarLoadPcx(char *filename);\r
 tileset_t planarLoadPcxTiles(char *filename, word twidth, word theight);\r
index 84b3eab063fafcdb6a2ea37161a9b98924662065..2c75c4eb0f81fadd95665d53ec6211a77f8837b0 100755 (executable)
@@ -25,7 +25,7 @@
 \r
 #include "src/lib/16_head.h"\r
 #include "src/lib/bakapee.h"\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/16_in.h"\r
 #include "src/lib/bitmap.h"\r
 #include "src/lib/mapread.h" //map is loaded here www\r
index 25437fcb03460886861838992dc9e2971e56b517..624b098f4fa01fe8956eede176b5e4671f563dc4 100755 (executable)
@@ -20,7 +20,7 @@
  *\r
  */\r
 \r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 \r
 global_game_variables_t gvar;\r
 \r
index 04beeff673d6377236e85bebd05f1245ff09005f..53e86c2d0c19409b80524eac9be4069c1ae31a83 100755 (executable)
@@ -20,7 +20,7 @@
  *\r
  */\r
 \r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/bakapee.h"\r
 \r
 global_game_variables_t gvar;\r
index 2f61443de3d0a72af5148d8fdba8e3680fbd019f..84a8323699855b657c370a37a64cbd96939d91a3 100755 (executable)
 #include <stdio.h>\r
 #include <dos.h>\r
 #include <string.h>\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/bitmap.h"\r
 //----#include "src/lib/planar.h"\r
 \r
 global_game_variables_t gvar;\r
+static word far* clockw= (word far*) 0x046C; /* 18.2hz clock */\r
 \r
 void main() {\r
        bitmap_t bmp;\r
index 167e1f6a46f955f2b8071112cec982b1ad1bad63..f92c300be87c7871db32ff7404e4b0312bf4530e 100755 (executable)
 #include <stdio.h>\r
 #include <dos.h>\r
 #include <string.h>\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/bitmap.h"\r
 //----#include "src/lib/planar.h"\r
 \r
 global_game_variables_t gvar;\r
+static word far* clockw= (word far*) 0x046C; /* 18.2hz clock */\r
 \r
 /*\r
 void\r
index eea4796ca6dc515ba0eedc765c0087a0d88857a9..e673302642796ac07a47734577c1aa4781227b1b 100755 (executable)
@@ -23,7 +23,7 @@
 #include <stdio.h>\r
 #include <dos.h>\r
 #include <string.h>\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/modex16/16planar.h"\r
 \r
 global_game_variables_t gvar;\r
index cb75a0fa248ae81e17025f162fe09489428c057d..dfbc7de857e89c923f66948880f643870382fc4b 100755 (executable)
  */\r
 \r
 #include <stdio.h>\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/16_in.h"\r
 #include "src/lib/scroll16.h"\r
 #include "src/lib/bakapee.h"\r
 \r
+static word far* clockw= (word far*) 0x046C; /* 18.2hz clock */\r
 global_game_variables_t gvar;\r
 player_t player[MaxPlayers];\r
 map_view_t mv[4];\r
index 722678a6f3f02e230c76280f4cf4ba5ef522933b..b4c33ee3c7f5315f574e20e2a39a2586dfa86c0f 100755 (executable)
@@ -22,7 +22,7 @@
 \r
 #include <stdio.h>\r
 #include <conio.h>\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/planar.h"\r
 //#include "src/lib/bitmap.h"\r
 \r
index d1f8bbbe3ee54e1ec2fead4424e8a66ee3f89bf3..7578e4ab090149e1b2e1a8a5092ec5f4dc7b56bc 100755 (executable)
@@ -2,7 +2,7 @@
 #define __TESUTO_H__\r
 \r
 #include "src/lib/16_head.h"\r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/16_in.h"\r
 #include <hw/cpu/cpu.h>\r
 #include <hw/dos/dos.h>\r
index e77fbc6e805ceebf9cc779bea029b0e66d71a081..2c8eaa89a5698d38df9629d8bf82541c84bb9b8d 100755 (executable)
  *\r
  */\r
 \r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/16_sprit.h"\r
 #include "src/lib/16_ca.h"\r
 #include "src/lib/16_mm.h"\r
 \r
+static word far* clockw= (word far*) 0x046C; /* 18.2hz clock */\r
+\r
 void main() {\r
        global_game_variables_t gvar;\r
        __segment sega;\r
index cdba1e9b992999f492f47aad0f1402c2bb53c8bf..9acf26493b03ca04e6c3e6c5ccc9dbf243ee2d41 100755 (executable)
  *\r
  */\r
 \r
-#include "src/lib/modex16.h"\r
+#include "src/lib/16_vl.h"\r
 #include "src/lib/16_sprit.h"\r
 #include "src/lib/16_tail.h"\r
 #include "src/lib/16_pm.h"\r
 #include "src/lib/16_ca.h"\r
 #include "src/lib/16_mm.h"\r
 \r
+static word far* clockw= (word far*) 0x046C; /* 18.2hz clock */\r
+\r
 void main() {\r
        static global_game_variables_t gvar;\r
-       __segment sega;\r
+       //__segment sega;\r
        memptr bigbuffer;\r
        int i;\r
        word start;\r
        float t1, t2;\r
        boolean baka;\r
-       byte *pal;\r
-       int size;\r
+       byte *pal=0;\r
+       int size=0;\r
        struct sprite spri;\r
-       vrl1_vgax_offset_t * off, *off1;\r
+       //vrl1_vgax_offset_t * off, *off1;\r
        struct vrs_container vrs;\r
        vrl1_vgax_offset_t **vrl_line_offsets;\r
        uint32_t huge *vrl_headers_offsets;\r
index c26af169b556455599b6b9319e1706a54f332990..fc489c2c5f4537dd2ef1aeda66015b68eb8b02a2 100755 (executable)
Binary files a/test.exe and b/test.exe differ
index a8a34c97014994b0cc89296c0c5def3970835185..31c4ed411655c2f8eecc3f18a69cd94a4c0878e7 100755 (executable)
Binary files a/test0.exe and b/test0.exe differ
index d4aeea4b58af9e921bf1dac62513962a12d1700f..68c88c980b6b66bfe5545ac71052f8e35e128a61 100755 (executable)
Binary files a/vgmtest.exe and b/vgmtest.exe differ