diff --git a/doc/manual.txt b/doc/manual.txt index a4b1d28..a1de562 100644 --- a/doc/manual.txt +++ b/doc/manual.txt @@ -82,9 +82,7 @@ You also must return to a base when the last enemy goes down. The bases may also be destroyed along with all the other terrain, but they regenerate in time. The game can be paused with key F11 (and unpaused with the same key). -You can also save a screenshot by pressing key F12 (fileformat is -640x480x256 RIX and filename is KOPSSHOT.RIX). The game can be run in -windowed mode if started with parameter -c1. + The game can be run in windowed mode if started with parameter -c1. .------------------------------------------------------------------------. | 3.1 Weapons | diff --git a/src/game.c b/src/game.c index 64fc715..0928211 100644 --- a/src/game.c +++ b/src/game.c @@ -40,8 +40,6 @@ /* #define VRC */ /* #define RASTER */ -#define SCREENSHOTS - int isqrt(int num) { return (int)sqrt((double)num); @@ -904,20 +902,6 @@ void game() } } - /* - * f12 saves screen to SHOT.RIX - */ -#ifdef SCREENSHOTS - if (key(K_F12)) { - gamepause = 1; - savescreenrix("kopsshot.rix"); - while (key(K_F12)) { - update(); - } - gamepause = 0; - } -#endif - /* * game pause */ diff --git a/src/gamefunc.c b/src/gamefunc.c index 2604f7d..ada704c 100644 --- a/src/gamefunc.c +++ b/src/gamefunc.c @@ -809,88 +809,3 @@ void newboom(int xp, int yp, char type, char transp, char speed) boom[nextboom].speed = speed; nextboom = (nextboom + 1) % MAXBOOMS; } - -void savescreenrix(char *fname) -{ - FILE *fp; - Uint8 r, g, b; - int a; - Uint8 *tmp; - Uint8 *tpic = NULL; - - fp = fopen(fname, "wb"); - tmp = (Uint8 *)malloc(307200); - if (tmp == NULL) { - jerror("SAVESCREENRIX/screen.malloc: No memory", 307200); - } - tpic = (Uint8 *)malloc(WINW * WINH + 4); - if (tpic == NULL) { - jerror("SAVESCREENRIX/tpic.malloc: No memory", WINW * WINH + 4); - } - util_loadpcx((char *)tpic, FILLERPICFILE, WINW * WINH); - if (gamewindowcolorrand) { - for (a = 0; a < WINW * WINH; a++) { - *(tpic + a) -= 8; - } - } - jcblockclip(0, 0, 320, 240, 0, 0, 639, 479, 640, tmp, tpic); - jcblockclip(320, 0, 320, 240, 0, 0, 639, 479, 640, tmp, tpic); - jcblockclip(0, 240, 320, 240, 0, 0, 639, 479, 640, tmp, tpic); - jcblockclip(320, 240, 320, 240, 0, 0, 639, 479, 640, tmp, tpic); - free(tpic); - tpic = NULL; - - if (plr[0].active) { - for (a = 0; a < WINH; a++) { - memcpy(tmp + (a + 240) * 640 + 320, plr[0].scr + a * WINW, WINW); - } - } - if (plr[1].active) { - for (a = 0; a < WINH; a++) { - memcpy(tmp + a * 640, plr[1].scr + a * WINW, WINW); - } - } - if (plr[2].active) { - for (a = 0; a < WINH; a++) { - memcpy(tmp + a * 640 + 320, plr[2].scr + a * WINW, WINW); - } - } - if (plr[3].active) { - for (a = 0; a < WINH; a++) { - memcpy(tmp + (a + 240) * 640, plr[3].scr + a * WINW, WINW); - } - } - b = 0x52; - fwrite(&b, 1, 1, fp); - b = 0x49; - fwrite(&b, 1, 1, fp); - b = 0x58; - fwrite(&b, 1, 1, fp); - b = 0x33; - fwrite(&b, 1, 1, fp); - b = 0x80; - fwrite(&b, 1, 1, fp); - b = 0x02; - fwrite(&b, 1, 1, fp); - b = 0xE0; - fwrite(&b, 1, 1, fp); - b = 0x01; - fwrite(&b, 1, 1, fp); - b = 0xAF; - fwrite(&b, 1, 1, fp); - b = 0x00; - fwrite(&b, 1, 1, fp); - for (a = 0; a < 256; a++) { - // outp(0x3c7,a); r=inp(0x3c9); g=inp(0x3c9); b=inp(0x3c9); - r = palette[a].r >> 2; - g = palette[a].g >> 2; - b = palette[a].b >> 2; - fwrite(&r, 1, 1, fp); - fwrite(&g, 1, 1, fp); - fwrite(&b, 1, 1, fp); - } - fwrite(tmp, 307200, 1, fp); - free(tmp); - tmp = NULL; - fclose(fp); -} diff --git a/src/gamefunc.h b/src/gamefunc.h index 98ae3ac..ea8a619 100644 --- a/src/gamefunc.h +++ b/src/gamefunc.h @@ -20,6 +20,5 @@ extern void newammocrap(int nro, int type); extern void newpickammo(); extern void newcrap(int xp, int yp, int type); extern void newboom(int xp, int yp, int type, int transp, int speed); -extern void savescreenrix(char *fname); #endif /* !GAMEFUNC_H_INCLUDED */