From: sparky4 Date: Tue, 10 Nov 2015 22:36:34 +0000 (-0600) Subject: fack X-Git-Url: http://4ch.mooo.com/gitweb/?p=16.git;a=commitdiff_plain;h=d4693f35f3fb3bec10b9e89860444420c1eb854b fack --- diff --git a/16.exe b/16.exe index b9870853..9c4b8195 100755 Binary files a/16.exe and b/16.exe differ diff --git a/exmmtest.exe b/exmmtest.exe index 6b0c7126..621d34e0 100755 Binary files a/exmmtest.exe and b/exmmtest.exe differ diff --git a/maptest.exe b/maptest.exe index b9ff97de..f6f1ce9e 100755 Binary files a/maptest.exe and b/maptest.exe differ diff --git a/pcxtest.exe b/pcxtest.exe index d2e447ab..ce8a91ef 100755 Binary files a/pcxtest.exe and b/pcxtest.exe differ diff --git a/pcxtest2.exe b/pcxtest2.exe index d46bc2cd..ff29be60 100755 Binary files a/pcxtest2.exe and b/pcxtest2.exe differ diff --git a/planrpcx.exe b/planrpcx.exe index 4dbcc1ab..4cfd67d9 100755 Binary files a/planrpcx.exe and b/planrpcx.exe differ diff --git a/scroll.exe b/scroll.exe index bbf5fb87..5da97c8d 100755 Binary files a/scroll.exe and b/scroll.exe differ diff --git a/src/lib/bitmap.c b/src/lib/bitmap.c index 4f25bbd4..d4341169 100755 --- a/src/lib/bitmap.c +++ b/src/lib/bitmap.c @@ -161,7 +161,7 @@ bitmapLoadPcxTiles(char *filename, word twidth, word theight) { /* allocate the pixel storage for the tiles */ ts.data = malloc(sizeof(byte*) * ts.ntiles); - ts.data[0] = malloc(sizeof(byte) * ts.ntiles * twidth * theight); + //ts.data[0] = malloc(sizeof(byte) * ts.ntiles * twidth * theight); for(i=1; i < ts.ntiles; i++) { ts.data[i] = ts.data[i-1] + twidth * theight; } diff --git a/src/lib/typdefst.h b/src/lib/typdefst.h index 2e1cd488..3d0fb2c6 100755 --- a/src/lib/typdefst.h +++ b/src/lib/typdefst.h @@ -48,7 +48,7 @@ typedef struct { } bitmap_t; typedef struct { - byte **data; + byte huge **data; word ntiles; /* the number of tiles */ word twidth; /* width of the tiles */ word theight; /* height of the tiles */ diff --git a/src/scroll.c b/src/scroll.c index b89d1291..eef7a87d 100755 --- a/src/scroll.c +++ b/src/scroll.c @@ -88,7 +88,7 @@ void main(int argc, char *argv[]) /* draw the tiles */ #ifdef MODEX ptr = map.data; - //mappalptr = map.tiles->btdata->palette; + mappalptr = map.tiles->data->palette; /* data */ p = bitmapLoadPcx("data/ptmp.pcx"); // load sprite @@ -126,7 +126,7 @@ void main(int argc, char *argv[]) //++++ player[0].data.offset=(paloffset/3); //++++ modexPalUpdate1(&player[0].data, &paloffset, 0, 0); //modexPalUpdate1(p.palette); - modexPalUpdate1(map.tiles->btdata->palette); + modexPalUpdate1(map.tiles->data->palette); //printf(" %d\n", sizeof(ptmp->data)); //printf("1: %d\n", paloffset); //++++ map.tiles->data->offset=(paloffset/3); @@ -356,9 +356,9 @@ void main(int argc, char *argv[]) if(IN_KeyDown(22)){ paloffset=0; modexPalBlack(); modexPalUpdate(&player[0].data, &paloffset, 0, 0); printf("1paloffset = %d\n", paloffset/3); - modexPalUpdate(map.tiles->data, &paloffset, 0, 0); + modexPalUpdate(map.tiles->data, &paloffset, 0, 0); printf("2paloffset = %d\n", paloffset/3); - pdump(bg->page); pdump(spri->page); } + pdump(bg->page); pdump(spri->page); } #endif #endif //pan switch diff --git a/test.exe b/test.exe index 30545c1f..51669ada 100755 Binary files a/test.exe and b/test.exe differ diff --git a/test2.exe b/test2.exe index 6cddf533..965a81eb 100755 Binary files a/test2.exe and b/test2.exe differ