From: sparky4 Date: Fri, 30 Jan 2015 00:00:15 +0000 (-0600) Subject: modified: scroll.exe X-Git-Url: http://4ch.mooo.com/gitweb/?a=commitdiff_plain;h=2a11c3d050096a8d755a3f619ff88573e571e35a;p=16.git modified: scroll.exe modified: src/scroll.c --- diff --git a/scroll.exe b/scroll.exe index 706aea7d..126442c8 100644 Binary files a/scroll.exe and b/scroll.exe differ diff --git a/src/scroll.c b/src/scroll.c index b91adf7d..9e197f09 100644 --- a/src/scroll.c +++ b/src/scroll.c @@ -60,7 +60,8 @@ void mapScrollDown(map_view_t *mv, byte offset); void mapGoTo(map_view_t *mv, int tx, int ty); void mapDrawTile(tiles_t *t, word i, page_t *page, word x, word y); void mapDrawRow(map_view_t *mv, int tx, int ty, word y); -void mapDrawCol(map_view_t *mv, int tx, int ty, word x); +void mapDrawCol(map_view_t *mv, int tx, int ty, word x); +void qclean(); void animatePlayer(map_view_t *src, map_view_t *dest, /*map_view_t *top, */sword d, short scrolloffsetswitch, int x, int y, int ls, int lp, bitmap_t *bmp); #define TILEWH 16 @@ -86,8 +87,9 @@ void main() { byte *ptr; actor_t player; //actor_t npc0; - - if(isEMS() || checkEMS()){ printf("%d\n", coretotalEMS()); emmhandle = mallocEMS(coretotalEMS()); } + +// atexit(qclean()); +// if(isEMS() || checkEMS()){ printf("%d\n", coretotalEMS()); emmhandle = mallocEMS(coretotalEMS()); } /* create the map */ map = allocMap(MAPX,MAPY); //20x15 is the resolution of the screen you can make maps smaller than 20x15 but the null space needs to be drawn properly @@ -519,13 +521,13 @@ void main() { //xmsfree(spri); //xmsfree(mask); //xmsreport(); - if(isEMS()) + /*if(isEMS()) { printf("%d\n", get_emem()); printf("%d\n", coretotalEMS()); dealloc_emem(emmhandle); printf("%d\n", coretotalEMS()); - } + }*/ switch(detectcpu()) { case 0: cpus = "8086/8088 or 186/88"; break; @@ -776,7 +778,14 @@ mapDrawCol(map_view_t *mv, int tx, int ty, word x) { } i += mv->map->width; } -} +} + +void qclean() +{ + modexLeave(); + setkb(0); +} + void animatePlayer(map_view_t *src, map_view_t *dest, /*map_view_t *top, */sword d, short scrolloffsetswitch, int x, int y, int ls, int lp, bitmap_t *bmp) {