From: Holger Schemel Date: Sat, 18 Jan 2003 11:19:57 +0000 (+0100) Subject: rnd-20030118-2-src X-Git-Tag: 3.0.0^2~174 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=5df470717980e8b1e8648a536ca620e4ca52a170;p=rocksndiamonds.git rnd-20030118-2-src --- diff --git a/src/cartoons.c b/src/cartoons.c index 45de45be..fa8152d9 100644 --- a/src/cartoons.c +++ b/src/cartoons.c @@ -297,17 +297,17 @@ void InitToons() { int graphic = toons[i].graphic; - toons[i].bitmap = new_graphic_info[graphic].bitmap; + toons[i].bitmap = graphic_info[graphic].bitmap; if (toons[i].src_x == -1 && toons[i].src_y == -1) { - int anim_frames = new_graphic_info[graphic].anim_frames; - int anim_delay = new_graphic_info[graphic].anim_delay; - int anim_mode = new_graphic_info[graphic].anim_mode; - int start_frame = new_graphic_info[graphic].anim_start_frame; + int anim_frames = graphic_info[graphic].anim_frames; + int anim_delay = graphic_info[graphic].anim_delay; + int anim_mode = graphic_info[graphic].anim_mode; + int start_frame = graphic_info[graphic].anim_start_frame; - toons[i].src_x = new_graphic_info[graphic].src_x; - toons[i].src_y = new_graphic_info[graphic].src_y; + toons[i].src_x = graphic_info[graphic].src_x; + toons[i].src_y = graphic_info[graphic].src_y; toons[i].width = TILEX; toons[i].height = TILEY; diff --git a/src/conftime.h b/src/conftime.h index 62f6e30a..e8274fb9 100644 --- a/src/conftime.h +++ b/src/conftime.h @@ -1 +1 @@ -#define COMPILE_DATE_STRING "[2003-01-17 19:59]" +#define COMPILE_DATE_STRING "[2003-01-18 12:18]" diff --git a/src/editor.c b/src/editor.c index c1a03a7c..688a63b7 100644 --- a/src/editor.c +++ b/src/editor.c @@ -1606,7 +1606,7 @@ static void ScrollMiniLevel(int from_x, int from_y, int scroll) static void CreateControlButtons() { - Bitmap *gd_bitmap = new_graphic_info[IMG_GLOBAL_DOOR].bitmap; + Bitmap *gd_bitmap = graphic_info[IMG_GLOBAL_DOOR].bitmap; struct GadgetInfo *gi; unsigned long event_mask; int i; @@ -1827,7 +1827,7 @@ static void CreateCounterButtons() for (j=0; j<2; j++) { - Bitmap *gd_bitmap = new_graphic_info[IMG_GLOBAL_DOOR].bitmap; + Bitmap *gd_bitmap = graphic_info[IMG_GLOBAL_DOOR].bitmap; struct GadgetInfo *gi; int id = (j == 0 ? counterbutton_info[i].gadget_id_down : @@ -2049,7 +2049,7 @@ static void CreateTextInputGadgets() for (i=0; i 1) +#define IS_ANIMATED(g) (graphic_info[g].anim_frames > 1) /* ------------------------------------------------------------------------- */ @@ -1081,7 +1081,7 @@ void InitGame() FadeToFront(); /* copy default game door content to main double buffer */ - BlitBitmap(new_graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, + BlitBitmap(graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, DOOR_GFX_PAGEX5, DOOR_GFX_PAGEY1, DXSIZE, DYSIZE, DX, DY); if (level_nr < 100) @@ -2018,9 +2018,9 @@ static void InitBeltMovement() int graphic = el2img(element); if (game.belt_dir[i] == MV_LEFT) - new_graphic_info[graphic].anim_mode &= ~ANIM_REVERSE; + graphic_info[graphic].anim_mode &= ~ANIM_REVERSE; else - new_graphic_info[graphic].anim_mode |= ANIM_REVERSE; + graphic_info[graphic].anim_mode |= ANIM_REVERSE; } } @@ -2102,9 +2102,9 @@ static void ToggleBeltSwitch(int x, int y) int graphic = el2img(element); if (belt_dir == MV_LEFT) - new_graphic_info[graphic].anim_mode &= ~ANIM_REVERSE; + graphic_info[graphic].anim_mode &= ~ANIM_REVERSE; else - new_graphic_info[graphic].anim_mode |= ANIM_REVERSE; + graphic_info[graphic].anim_mode |= ANIM_REVERSE; } for (yy=0; yyheight * 2 / 3 : TILEY) / TILEY; int *parameter = image_files[i].parameter; - new_graphic_info[i].bitmap = src_bitmap; + graphic_info[i].bitmap = src_bitmap; - new_graphic_info[i].src_x = parameter[GFX_ARG_XPOS] * TILEX; - new_graphic_info[i].src_y = parameter[GFX_ARG_YPOS] * TILEY; - new_graphic_info[i].offset_x = parameter[GFX_ARG_OFFSET]; - new_graphic_info[i].offset_y = 0; + graphic_info[i].src_x = parameter[GFX_ARG_XPOS] * TILEX; + graphic_info[i].src_y = parameter[GFX_ARG_YPOS] * TILEY; + graphic_info[i].offset_x = parameter[GFX_ARG_OFFSET]; + graphic_info[i].offset_y = 0; /* animation frames are ordered vertically instead of horizontally */ if (parameter[GFX_ARG_VERTICAL]) { - new_graphic_info[i].offset_x = 0; - new_graphic_info[i].offset_y = parameter[GFX_ARG_OFFSET]; + graphic_info[i].offset_x = 0; + graphic_info[i].offset_y = parameter[GFX_ARG_OFFSET]; } /* optionally, the x and y offset of frames can be specified directly */ if (parameter[GFX_ARG_XOFFSET] != GFX_ARG_UNDEFINED_VALUE) - new_graphic_info[i].offset_x = parameter[GFX_ARG_XOFFSET]; + graphic_info[i].offset_x = parameter[GFX_ARG_XOFFSET]; if (parameter[GFX_ARG_YOFFSET] != GFX_ARG_UNDEFINED_VALUE) - new_graphic_info[i].offset_y = parameter[GFX_ARG_YOFFSET]; + graphic_info[i].offset_y = parameter[GFX_ARG_YOFFSET]; /* automatically determine correct number of frames, if not defined */ if (parameter[GFX_ARG_FRAMES] != GFX_ARG_UNDEFINED_VALUE) - new_graphic_info[i].anim_frames = parameter[GFX_ARG_FRAMES]; + graphic_info[i].anim_frames = parameter[GFX_ARG_FRAMES]; else if (parameter[GFX_ARG_XPOS] == 0 && !parameter[GFX_ARG_VERTICAL]) - new_graphic_info[i].anim_frames = num_xtiles; + graphic_info[i].anim_frames = num_xtiles; else if (parameter[GFX_ARG_YPOS] == 0 && parameter[GFX_ARG_VERTICAL]) - new_graphic_info[i].anim_frames = num_ytiles; + graphic_info[i].anim_frames = num_ytiles; else - new_graphic_info[i].anim_frames = 1; + graphic_info[i].anim_frames = 1; - new_graphic_info[i].anim_delay = parameter[GFX_ARG_DELAY]; - if (new_graphic_info[i].anim_delay == 0) /* delay must be at least 1 */ - new_graphic_info[i].anim_delay = 1; + graphic_info[i].anim_delay = parameter[GFX_ARG_DELAY]; + if (graphic_info[i].anim_delay == 0) /* delay must be at least 1 */ + graphic_info[i].anim_delay = 1; /* set mode for animation frame order */ if (parameter[GFX_ARG_MODE_LOOP]) - new_graphic_info[i].anim_mode = ANIM_LOOP; + graphic_info[i].anim_mode = ANIM_LOOP; else if (parameter[GFX_ARG_MODE_LINEAR]) - new_graphic_info[i].anim_mode = ANIM_LINEAR; + graphic_info[i].anim_mode = ANIM_LINEAR; else if (parameter[GFX_ARG_MODE_PINGPONG]) - new_graphic_info[i].anim_mode = ANIM_PINGPONG; + graphic_info[i].anim_mode = ANIM_PINGPONG; else if (parameter[GFX_ARG_MODE_PINGPONG2]) - new_graphic_info[i].anim_mode = ANIM_PINGPONG2; + graphic_info[i].anim_mode = ANIM_PINGPONG2; else if (parameter[GFX_ARG_MODE_RANDOM]) - new_graphic_info[i].anim_mode = ANIM_RANDOM; - else if (new_graphic_info[i].anim_frames > 1) - new_graphic_info[i].anim_mode = ANIM_LOOP; + graphic_info[i].anim_mode = ANIM_RANDOM; + else if (graphic_info[i].anim_frames > 1) + graphic_info[i].anim_mode = ANIM_LOOP; else - new_graphic_info[i].anim_mode = ANIM_NONE; + graphic_info[i].anim_mode = ANIM_NONE; /* set additional flag to play animation frames in reverse order */ if (parameter[GFX_ARG_MODE_REVERSE]) - new_graphic_info[i].anim_mode |= ANIM_REVERSE; + graphic_info[i].anim_mode |= ANIM_REVERSE; /* set first frame of animation after determining animation mode */ - new_graphic_info[i].anim_start_frame = parameter[GFX_ARG_START_FRAME]; + graphic_info[i].anim_start_frame = parameter[GFX_ARG_START_FRAME]; /* automatically determine correct start frame, if not defined */ if (parameter[GFX_ARG_START_FRAME] == GFX_ARG_UNDEFINED_VALUE) - new_graphic_info[i].anim_start_frame = 0; - else if (new_graphic_info[i].anim_mode & ANIM_REVERSE) - new_graphic_info[i].anim_start_frame = - new_graphic_info[i].anim_frames - parameter[GFX_ARG_START_FRAME] - 1; + graphic_info[i].anim_start_frame = 0; + else if (graphic_info[i].anim_mode & ANIM_REVERSE) + graphic_info[i].anim_start_frame = + graphic_info[i].anim_frames - parameter[GFX_ARG_START_FRAME] - 1; /* animation synchronized with global frame counter, not move position */ - new_graphic_info[i].anim_global_sync = parameter[GFX_ARG_GLOBAL_SYNC]; + graphic_info[i].anim_global_sync = parameter[GFX_ARG_GLOBAL_SYNC]; /* set global_sync for all animations with undefined "animation action" */ if (parameter[GFX_ARG_GLOBAL_SYNC] == GFX_ARG_UNDEFINED_VALUE) - new_graphic_info[i].anim_global_sync = + graphic_info[i].anim_global_sync = (gfx_action[i] == GFX_ACTION_DEFAULT ? TRUE : FALSE); /* "linear" animations are never globally synchronized */ if (parameter[GFX_ARG_MODE_LINEAR]) - new_graphic_info[i].anim_global_sync = FALSE; + graphic_info[i].anim_global_sync = FALSE; /* now check if no animation frames are outside of the loaded image */ - if (new_graphic_info[i].bitmap == NULL) + if (graphic_info[i].bitmap == NULL) continue; /* skip check for optional images that are undefined */ first_frame = 0; @@ -933,7 +930,7 @@ static void InitGraphicInfo() src_x, src_y); } - last_frame = new_graphic_info[i].anim_frames - 1; + last_frame = graphic_info[i].anim_frames - 1; getGraphicSource(i, last_frame, &src_bitmap, &src_x, &src_y); if (src_x < 0 || src_y < 0 || src_x + TILEX > src_bitmap->width || @@ -962,17 +959,17 @@ static void InitGraphicInfo() clip_gc_valuemask, &clip_gc_values); } - new_graphic_info[i].clip_mask = + graphic_info[i].clip_mask = XCreatePixmap(display, window->drawable, TILEX, TILEY, 1); src_pixmap = src_bitmap->clip_mask; - XCopyArea(display, src_pixmap, new_graphic_info[i].clip_mask, + XCopyArea(display, src_pixmap, graphic_info[i].clip_mask, copy_clipmask_gc, src_x, src_y, TILEX, TILEY, 0, 0); clip_gc_values.graphics_exposures = False; - clip_gc_values.clip_mask = new_graphic_info[i].clip_mask; + clip_gc_values.clip_mask = graphic_info[i].clip_mask; clip_gc_valuemask = GCGraphicsExposures | GCClipMask; - new_graphic_info[i].clip_gc = + graphic_info[i].clip_gc = XCreateGC(display, window->drawable, clip_gc_valuemask, &clip_gc_values); #endif } diff --git a/src/main.c b/src/main.c index 00347a4f..09ff42d4 100644 --- a/src/main.c +++ b/src/main.c @@ -85,65 +85,6 @@ struct SetupInfo setup; struct GameInfo game; struct GlobalInfo global; -/* filenames of sound effects */ -char *sound_name[NUM_SOUNDS] = -{ - "amoebe.wav", - "antigrav.wav", - "autsch.wav", - "blurb.wav", - "bong.wav", - "buing.wav", - "deng.wav", - "fuel.wav", - "gong.wav", - "halloffame.wav", - "holz.wav", - "hui.wav", - "kabumm.wav", - "kink.wav", - "klapper.wav", - "kling.wav", - "klopf.wav", - "klumpf.wav", - "knack.wav", - "knurk.wav", - "krach.wav", - "lachen.wav", - "laser.wav", - "miep.wav", - "njam.wav", - "oeffnen.wav", - "pling.wav", - "pong.wav", - "pusch.wav", - "quiek.wav", - "quirk.wav", - "rhythmloop.wav", - "roaaar.wav", - "roehr.wav", - "rumms.wav", - "schlopp.wav", - "schlurf.wav", - "schrff.wav", - "schwirr.wav", - "sirr.wav", - "slurp.wav", - "sproing.wav", - "warnton.wav", - "whoosh.wav", - "zisch.wav", - "base.wav", - "infotron.wav", - "zonkdown.wav", - "zonkpush.wav", - "bug.wav", - "boom.wav", - "booom.wav", - "exit.wav", - "empty.wav", - "gate.wav" -}; /* this is used to reduce memory usage of the different animation types */ int graphics_action_mapping[] = @@ -2846,10 +2787,7 @@ struct ElementInfo element_info[MAX_NUM_ELEMENTS] = } }; -#if 0 -struct GraphicInfo graphic_info[MAX_GRAPHICS]; -#endif -struct NewGraphicInfo new_graphic_info[NUM_IMAGE_FILES]; +struct NewGraphicInfo graphic_info[NUM_IMAGE_FILES]; /* ========================================================================= */ diff --git a/src/main.h b/src/main.h index 394dc098..7f92ca8f 100644 --- a/src/main.h +++ b/src/main.h @@ -274,49 +274,7 @@ #define MICROLEV_YPOS (SX + 12 * TILEY - MICRO_TILEY) #define MICROLABEL_YPOS (MICROLEV_YPOS + MICROLEV_YSIZE + 7) -#define MINI_GFX_STARTX 0 -#define MINI_GFX_STARTY 448 -#define MICRO_GFX_STARTX 384 -#define MICRO_GFX_STARTY 448 -#define GFX_PER_LINE 16 -#define MINI_GFX_PER_LINE 16 -#define MICRO_GFX_PER_LINE 16 - -#define MINI_FONT_STARTX 0 -#define MINI_FONT_STARTY 160 -#define MICRO_FONT_STARTX 384 -#define MICRO_FONT_STARTY 160 - -#define HEROES_PER_LINE 16 - -#define MINI_SP_STARTX 0 -#define MINI_SP_STARTY 512 -#define MICRO_SP_STARTX 384 -#define MICRO_SP_STARTY 512 -#define SP_PER_LINE 16 -#define MINI_SP_PER_LINE 16 -#define MICRO_SP_PER_LINE 16 - -#define MINI_DC_STARTX 0 -#define MINI_DC_STARTY 512 -#define MICRO_DC_STARTX 384 -#define MICRO_DC_STARTY 512 -#define DC_PER_LINE 16 -#define MINI_DC_PER_LINE 16 -#define MICRO_DC_PER_LINE 16 - -#define MINI_MORE_STARTX 0 -#define MINI_MORE_STARTY 256 -#define MICRO_MORE_STARTX 384 -#define MICRO_MORE_STARTY 256 -#define MORE_PER_LINE 16 -#define MINI_MORE_PER_LINE 16 -#define MICRO_MORE_PER_LINE 16 - -/* game elements: -** 0 <= element < xxx: real elements, stored in level file -** xxx <= element < yyy: flag elements, only used at runtime -*/ + /* "real" level file elements */ #define EL_UNDEFINED -1 @@ -799,575 +757,6 @@ #define MAX_NUM_ELEMENTS (EL_FIRST_DUMMY + 36) -/* game graphics: -** 0 - 255: graphics from "RocksElements" -** 256 - 511: graphics from "RocksFont" -** 512 - 767: graphics from "RocksHeroes" -** 768 - 1023: graphics from "RocksSP" -** 1024 - 1279: graphics from "RocksDC" -** 1280 - 1535: graphics from "RocksMore" -*/ - -#define GFX_START_ROCKSELEMENTS 0 -#define GFX_END_ROCKSELEMENTS 255 -#define GFX_START_ROCKSFONT 256 -#define GFX_END_ROCKSFONT 511 -#define GFX_START_ROCKSHEROES 512 -#define GFX_END_ROCKSHEROES 767 -#define GFX_START_ROCKSSP 768 -#define GFX_END_ROCKSSP 1023 -#define GFX_START_ROCKSDC 1024 -#define GFX_END_ROCKSDC 1279 -#define GFX_START_ROCKSMORE 1280 -#define GFX_END_ROCKSMORE 1535 - -#if 0 -#define NUM_TILES 1536 /* see above: MAX_GRAPHICS */ -#endif - -/* graphics from "RocksScreen" */ -/* Zeile 0 (0) */ -#define GFX_LEERRAUM (-1) -#define GFX_ERDREICH 0 -#define GFX_ERDENRAND 1 -#define GFX_MORAST_LEER 2 -#define GFX_MORAST_VOLL 3 -#define GFX_BETON 4 -#define GFX_MAUERWERK 5 -#define GFX_FELSBODEN 6 -#define GFX_EDELSTEIN 8 -#define GFX_DIAMANT 10 -#define GFX_FELSBROCKEN 12 -/* Zeile 1 (16) */ -#define GFX_BADEWANNE1 16 -#define GFX_SALZSAEURE 17 -#define GFX_BADEWANNE2 18 - -/* -#define GFX_UNSICHTBAR 19 -*/ - -#define GFX_SCHLUESSEL1 20 -#define GFX_SCHLUESSEL2 21 -#define GFX_SCHLUESSEL3 22 -#define GFX_SCHLUESSEL4 23 -#define GFX_LIFE 24 -#define GFX_LIFE_ASYNC 25 -#define GFX_BADEWANNE 26 -#define GFX_BOMBE 27 -#define GFX_KOKOSNUSS 28 -#define GFX_CRACKINGNUT 29 -/* Zeile 2 (32) */ -#define GFX_BADEWANNE3 32 -#define GFX_BADEWANNE4 33 -#define GFX_BADEWANNE5 34 -#define GFX_SMILEY 35 -#define GFX_PFORTE1 36 -#define GFX_PFORTE2 37 -#define GFX_PFORTE3 38 -#define GFX_PFORTE4 39 -#define GFX_PFORTE1X 40 -#define GFX_PFORTE2X 41 -#define GFX_PFORTE3X 42 -#define GFX_PFORTE4X 43 -/* Zeile 3 (48) */ -#define GFX_DYNAMIT_AUS 48 -#define GFX_DYNAMIT 49 -#define GFX_FLIEGER 56 -#define GFX_FLIEGER_RIGHT 56 -#define GFX_FLIEGER_UP 58 -#define GFX_FLIEGER_LEFT 60 -#define GFX_FLIEGER_DOWN 62 -/* Zeile 4 (64) */ -#define GFX_EXPLOSION 64 -#define GFX_KAEFER 72 -#define GFX_KAEFER_RIGHT 72 -#define GFX_KAEFER_UP 74 -#define GFX_KAEFER_LEFT 76 -#define GFX_KAEFER_DOWN 78 -/* Zeile 5 (80) */ -#define GFX_MAMPFER 80 -#define GFX_ROBOT 84 -#define GFX_PACMAN 88 -#define GFX_PACMAN_RIGHT 88 -#define GFX_PACMAN_UP 90 -#define GFX_PACMAN_LEFT 92 -#define GFX_PACMAN_DOWN 94 -/* Zeile 6 (96) */ -#define GFX_ABLENK 96 -#define GFX_ABLENK_EIN GFX_ABLENK -#define GFX_ABLENK_AUS GFX_ABLENK -#define GFX_AMOEBE_NASS 100 -#define GFX_TROPFEN 101 -#define GFX_AMOEBING GFX_TROPFEN -#define GFX_AMOEBE_LEBT 104 -#define GFX_AMOEBE_NORM GFX_AMOEBE_LEBT -#define GFX_AMOEBE_TOT 108 -#define GFX_AMOEBA2DIAM GFX_AMOEBE_TOT -/* Zeile 7 (112) */ -#define GFX_BIRNE_AUS 112 -#define GFX_BIRNE_EIN 113 -#define GFX_ZEIT_VOLL 114 -#define GFX_ZEIT_LEER 115 -#define GFX_SPIELER1 116 -#define GFX_SPIELER2 117 -#define GFX_SPIELER3 118 -#define GFX_SPIELER4 119 -#define GFX_AMOEBE_VOLL 120 -#define GFX_AMOEBE_BD GFX_AMOEBE_VOLL -#define GFX_SOKOBAN_OBJEKT 121 -#define GFX_SOKOBAN_FELD_LEER 122 -#define GFX_SOKOBAN_FELD_VOLL 123 -#define GFX_GEBLUBBER 124 -/* Zeile 8 (128) */ -#define GFX_MAGIC_WALL_OFF 128 -#define GFX_MAGIC_WALL_EMPTY GFX_MAGIC_WALL_OFF -#define GFX_MAGIC_WALL_FULL GFX_MAGIC_WALL_OFF -#define GFX_MAGIC_WALL_DEAD GFX_MAGIC_WALL_OFF -#define GFX_ERZ_EDEL 132 -#define GFX_ERZ_DIAM 133 -#define GFX_ERZ_EDEL_ROT 134 -#define GFX_ERZ_EDEL_LILA 135 -#define GFX_ERZ_EDEL_GELB 136 -#define GFX_ERZ_EDEL_BD 137 -#define GFX_EDELSTEIN_GELB 138 -#define GFX_KUGEL_ROT 140 -#define GFX_KUGEL_BLAU 141 -#define GFX_KUGEL_GELB 142 -#define GFX_KUGEL_GRAU 143 -/* Zeile 9 (144) */ -#define GFX_PINGUIN 144 -#define GFX_MOLE 145 -#define GFX_SCHWEIN 146 -#define GFX_DRACHE 147 -#define GFX_MAUER_XY 148 -#define GFX_MAUER_X 149 -#define GFX_MAUER_Y 150 -#define GFX_EDELSTEIN_ROT 152 -#define GFX_EDELSTEIN_LILA 154 -#define GFX_DYNABOMB_XL 156 -#define GFX_BLACK_ORB 157 -#define GFX_SPEED_PILL 158 -#define GFX_SONDE 159 -/* Zeile 10 (160) */ -#define GFX_EDELSTEIN_BD 163 -#define GFX_MAUER_RIGHT 165 -#define GFX_MAUER_R1 GFX_MAUER_RIGHT -#define GFX_MAUER_R 167 -#define GFX_MAUER_LEFT 168 -#define GFX_MAUER_L1 GFX_MAUER_LEFT -#define GFX_MAUER_L 170 -#define GFX_MAUER_LEBT 171 -#define GFX_MAGIC_WALL_BD_OFF 172 -#define GFX_MAGIC_WALL_BD_EMPTY GFX_MAGIC_WALL_BD_OFF -#define GFX_MAGIC_WALL_BD_FULL GFX_MAGIC_WALL_BD_OFF -#define GFX_MAGIC_WALL_BD_DEAD GFX_MAGIC_WALL_BD_OFF -/* Zeile 11 (176) */ -#define GFX_AUSGANG_ZU 176 -#define GFX_AUSGANG_ACT 177 -#define GFX_AUSGANG_AUF 180 -#define GFX_MAMPFER2 184 -#define GFX_DYNABOMB 188 -#define GFX_DYNABOMB_NR 188 -#define GFX_DYNABOMB_SZ 191 -/* Zeile 12 (192) */ -#define GFX_PFEIL_LEFT 192 -#define GFX_PFEIL_RIGHT 193 -#define GFX_PFEIL_UP 194 -#define GFX_PFEIL_DOWN 195 -#define GFX_BUTTERFLY 196 -#define GFX_FIREFLY 198 -#define GFX_BUTTERFLY_RIGHT 200 -#define GFX_BUTTERFLY_UP 201 -#define GFX_BUTTERFLY_LEFT 202 -#define GFX_BUTTERFLY_DOWN 203 -#define GFX_FIREFLY_RIGHT 204 -#define GFX_FIREFLY_UP 205 -#define GFX_FIREFLY_LEFT 206 -#define GFX_FIREFLY_DOWN 207 - -/* only available as size MINI_TILE */ -#define GFX_VSTEEL_UPPER_LEFT 208 -#define GFX_VSTEEL_UPPER_RIGHT 209 -#define GFX_VSTEEL_LOWER_LEFT 210 -#define GFX_VSTEEL_LOWER_RIGHT 211 -#define GFX_VSTEEL_HORIZONTAL 212 -#define GFX_VSTEEL_VERTICAL 213 -#define GFX_ISTEEL_UPPER_LEFT 214 -#define GFX_ISTEEL_UPPER_RIGHT 215 -#define GFX_ISTEEL_LOWER_LEFT 216 -#define GFX_ISTEEL_LOWER_RIGHT 217 -#define GFX_ISTEEL_HORIZONTAL 218 -#define GFX_ISTEEL_VERTICAL 219 - -/* elements with graphics borrowed from other elements */ -#define GFX_SCHLUESSEL GFX_SCHLUESSEL1 -#define GFX_SPIELFIGUR GFX_SPIELER1 - -/* graphics from "RocksHeroes" */ -#define GFX_SPIELER1_DOWN (GFX_START_ROCKSHEROES + 0*HEROES_PER_LINE + 0) -#define GFX_SPIELER1_UP (GFX_START_ROCKSHEROES + 0*HEROES_PER_LINE + 4) -#define GFX_SPIELER1_LEFT (GFX_START_ROCKSHEROES + 1*HEROES_PER_LINE + 0) -#define GFX_SPIELER1_RIGHT (GFX_START_ROCKSHEROES + 1*HEROES_PER_LINE + 4) -#define GFX_SPIELER1_PUSH_RIGHT (GFX_START_ROCKSHEROES + 2*HEROES_PER_LINE + 0) -#define GFX_SPIELER1_PUSH_LEFT (GFX_START_ROCKSHEROES + 2*HEROES_PER_LINE + 4) -#define GFX_SPIELER2_DOWN (GFX_START_ROCKSHEROES + 3*HEROES_PER_LINE + 0) -#define GFX_SPIELER2_UP (GFX_START_ROCKSHEROES + 3*HEROES_PER_LINE + 4) -#define GFX_SPIELER2_LEFT (GFX_START_ROCKSHEROES + 4*HEROES_PER_LINE + 0) -#define GFX_SPIELER2_RIGHT (GFX_START_ROCKSHEROES + 4*HEROES_PER_LINE + 4) -#define GFX_SPIELER2_PUSH_RIGHT (GFX_START_ROCKSHEROES + 5*HEROES_PER_LINE + 0) -#define GFX_SPIELER2_PUSH_LEFT (GFX_START_ROCKSHEROES + 5*HEROES_PER_LINE + 4) -#define GFX_SPIELER3_DOWN (GFX_START_ROCKSHEROES + 6*HEROES_PER_LINE + 0) -#define GFX_SPIELER3_UP (GFX_START_ROCKSHEROES + 6*HEROES_PER_LINE + 4) -#define GFX_SPIELER3_LEFT (GFX_START_ROCKSHEROES + 7*HEROES_PER_LINE + 0) -#define GFX_SPIELER3_RIGHT (GFX_START_ROCKSHEROES + 7*HEROES_PER_LINE + 4) -#define GFX_SPIELER3_PUSH_RIGHT (GFX_START_ROCKSHEROES + 8*HEROES_PER_LINE + 0) -#define GFX_SPIELER3_PUSH_LEFT (GFX_START_ROCKSHEROES + 8*HEROES_PER_LINE + 4) -#define GFX_SPIELER4_DOWN (GFX_START_ROCKSHEROES + 9*HEROES_PER_LINE + 0) -#define GFX_SPIELER4_UP (GFX_START_ROCKSHEROES + 9*HEROES_PER_LINE + 4) -#define GFX_SPIELER4_LEFT (GFX_START_ROCKSHEROES +10*HEROES_PER_LINE + 0) -#define GFX_SPIELER4_RIGHT (GFX_START_ROCKSHEROES +10*HEROES_PER_LINE + 4) -#define GFX_SPIELER4_PUSH_RIGHT (GFX_START_ROCKSHEROES +11*HEROES_PER_LINE + 0) -#define GFX_SPIELER4_PUSH_LEFT (GFX_START_ROCKSHEROES +11*HEROES_PER_LINE + 4) -#define GFX_MAUER_DOWN (GFX_START_ROCKSHEROES +12*HEROES_PER_LINE + 0) -#define GFX_MAUER_UP (GFX_START_ROCKSHEROES +12*HEROES_PER_LINE + 3) -#define GFX2_SHIELD_PASSIVE (GFX_START_ROCKSHEROES +13*HEROES_PER_LINE + 1) -#define GFX2_SHIELD_ACTIVE (GFX_START_ROCKSHEROES +13*HEROES_PER_LINE + 5) - -#define GFX_SONDE_START (GFX_START_ROCKSHEROES + 9*HEROES_PER_LINE + 8) -#define GFX_SCHWEIN_DOWN (GFX_START_ROCKSHEROES + 0*HEROES_PER_LINE + 8) -#define GFX_SCHWEIN_UP (GFX_START_ROCKSHEROES + 0*HEROES_PER_LINE +12) -#define GFX_SCHWEIN_LEFT (GFX_START_ROCKSHEROES + 1*HEROES_PER_LINE + 8) -#define GFX_SCHWEIN_RIGHT (GFX_START_ROCKSHEROES + 1*HEROES_PER_LINE +12) -#define GFX_DRACHE_DOWN (GFX_START_ROCKSHEROES + 2*HEROES_PER_LINE + 8) -#define GFX_DRACHE_UP (GFX_START_ROCKSHEROES + 2*HEROES_PER_LINE +12) -#define GFX_DRACHE_LEFT (GFX_START_ROCKSHEROES + 3*HEROES_PER_LINE + 8) -#define GFX_DRACHE_RIGHT (GFX_START_ROCKSHEROES + 3*HEROES_PER_LINE +12) -/* -#define GFX_MOLE_DOWN (GFX_START_ROCKSHEROES + 4*HEROES_PER_LINE + 8) -#define GFX_MOLE_UP (GFX_START_ROCKSHEROES + 4*HEROES_PER_LINE +12) -#define GFX_MOLE_LEFT (GFX_START_ROCKSHEROES + 5*HEROES_PER_LINE + 8) -#define GFX_MOLE_RIGHT (GFX_START_ROCKSHEROES + 5*HEROES_PER_LINE +12) -*/ -#define GFX_PINGUIN_DOWN (GFX_START_ROCKSHEROES + 6*HEROES_PER_LINE + 8) -#define GFX_PINGUIN_UP (GFX_START_ROCKSHEROES + 6*HEROES_PER_LINE +12) -#define GFX_PINGUIN_LEFT (GFX_START_ROCKSHEROES + 7*HEROES_PER_LINE + 8) -#define GFX_PINGUIN_RIGHT (GFX_START_ROCKSHEROES + 7*HEROES_PER_LINE +12) -#define GFX_BLURB_LEFT (GFX_START_ROCKSHEROES +10*HEROES_PER_LINE + 8) -#define GFX_BLURB_RIGHT (GFX_START_ROCKSHEROES +10*HEROES_PER_LINE +12) -#define GFX_FUNKELN_BLAU (GFX_START_ROCKSHEROES +11*HEROES_PER_LINE + 9) -#define GFX_FUNKELN_WEISS (GFX_START_ROCKSHEROES +11*HEROES_PER_LINE +13) -#define GFX_FLAMMEN_LEFT (GFX_START_ROCKSHEROES +12*HEROES_PER_LINE + 8) -#define GFX_FLAMMEN_RIGHT (GFX_START_ROCKSHEROES +13*HEROES_PER_LINE + 8) -#define GFX_FLAMMEN_UP (GFX_START_ROCKSHEROES +14*HEROES_PER_LINE + 8) -#define GFX_FLAMMEN_DOWN (GFX_START_ROCKSHEROES +15*HEROES_PER_LINE + 8) - -/* graphics from "RocksSP" */ -#define GFX_SP_EMPTY (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 0) -/* -#define GFX_SP_ZONK (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 1) -*/ -#define GFX_SP_BASE (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 2) -#define GFX_SP_MURPHY (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 3) -#define GFX_SP_INFOTRON (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 4) -#define GFX_SP_CHIP_SINGLE (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 5) -#define GFX_SP_HARD_GRAY (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 6) -#define GFX_SP_EXIT (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 7) -#define GFX_SP_DISK_ORANGE (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 0) -#define GFX_SP_PORT1_RIGHT (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 1) -#define GFX_SP_PORT1_DOWN (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 2) -#define GFX_SP_PORT1_LEFT (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 3) -#define GFX_SP_PORT1_UP (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 4) -#define GFX_SP_PORT2_RIGHT (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 5) -#define GFX_SP_PORT2_DOWN (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 6) -#define GFX_SP_PORT2_LEFT (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 7) -#define GFX_SP_PORT2_UP (GFX_START_ROCKSSP + 2 * SP_PER_LINE + 0) -#define GFX_SP_SNIKSNAK (GFX_START_ROCKSSP + 2 * SP_PER_LINE + 1) -#define GFX_SP_DISK_YELLOW (GFX_START_ROCKSSP + 2 * SP_PER_LINE + 2) -#define GFX_SP_TERMINAL (GFX_START_ROCKSSP + 2 * SP_PER_LINE + 3) -#define GFX_SP_DISK_RED (GFX_START_ROCKSSP + 2 * SP_PER_LINE + 4) -#define GFX_SP_PORT_Y (GFX_START_ROCKSSP + 2 * SP_PER_LINE + 5) -#define GFX_SP_PORT_X (GFX_START_ROCKSSP + 2 * SP_PER_LINE + 6) -#define GFX_SP_PORT_XY (GFX_START_ROCKSSP + 2 * SP_PER_LINE + 7) -#define GFX_SP_ELECTRON (GFX_START_ROCKSSP + 3 * SP_PER_LINE + 0) -#define GFX_SP_BUG (GFX_START_ROCKSSP + 3 * SP_PER_LINE + 1) -#define GFX_SP_CHIP_LEFT (GFX_START_ROCKSSP + 3 * SP_PER_LINE + 2) -#define GFX_SP_CHIP_RIGHT (GFX_START_ROCKSSP + 3 * SP_PER_LINE + 3) -#define GFX_SP_HARD_BASE1 (GFX_START_ROCKSSP + 3 * SP_PER_LINE + 4) -#define GFX_SP_HARD_GREEN (GFX_START_ROCKSSP + 3 * SP_PER_LINE + 5) -#define GFX_SP_HARD_BLUE (GFX_START_ROCKSSP + 3 * SP_PER_LINE + 6) -#define GFX_SP_HARD_RED (GFX_START_ROCKSSP + 3 * SP_PER_LINE + 7) -#define GFX_SP_HARD_YELLOW (GFX_START_ROCKSSP + 4 * SP_PER_LINE + 0) -#define GFX_SP_HARD_BASE2 (GFX_START_ROCKSSP + 4 * SP_PER_LINE + 1) -#define GFX_SP_HARD_BASE3 (GFX_START_ROCKSSP + 4 * SP_PER_LINE + 2) -#define GFX_SP_HARD_BASE4 (GFX_START_ROCKSSP + 4 * SP_PER_LINE + 3) -#define GFX_SP_HARD_BASE5 (GFX_START_ROCKSSP + 4 * SP_PER_LINE + 4) -#define GFX_SP_HARD_BASE6 (GFX_START_ROCKSSP + 4 * SP_PER_LINE + 5) -#define GFX_SP_CHIP_UPPER (GFX_START_ROCKSSP + 4 * SP_PER_LINE + 6) -#define GFX_SP_CHIP_LOWER (GFX_START_ROCKSSP + 4 * SP_PER_LINE + 7) - -#define GFX_INVISIBLE_STEEL_ON (GFX_START_ROCKSSP + 5 * SP_PER_LINE + 1) -#define GFX_SAND_INVISIBLE_ON (GFX_START_ROCKSSP + 5 * SP_PER_LINE + 2) -#define GFX_INVISIBLE_STEEL (GFX_START_ROCKSSP + 5 * SP_PER_LINE + 3) -#define GFX_UNSICHTBAR_ON (GFX_START_ROCKSSP + 5 * SP_PER_LINE + 5) -#define GFX_SAND_INVISIBLE (GFX_START_ROCKSSP + 5 * SP_PER_LINE + 6) -#define GFX_UNSICHTBAR (GFX_START_ROCKSSP + 5 * SP_PER_LINE + 7) - -#define GFX_SP_ZONK (GFX_START_ROCKSSP + 6 * SP_PER_LINE + 0) - -#define GFX_EM_KEY_1 (GFX_START_ROCKSSP + 6 * SP_PER_LINE + 4) -#define GFX_EM_KEY_2 (GFX_START_ROCKSSP + 6 * SP_PER_LINE + 5) -#define GFX_EM_KEY_3 (GFX_START_ROCKSSP + 6 * SP_PER_LINE + 6) -#define GFX_EM_KEY_4 (GFX_START_ROCKSSP + 6 * SP_PER_LINE + 7) -#define GFX_EM_GATE_1 (GFX_START_ROCKSSP + 7 * SP_PER_LINE + 0) -#define GFX_EM_GATE_2 (GFX_START_ROCKSSP + 7 * SP_PER_LINE + 1) -#define GFX_EM_GATE_3 (GFX_START_ROCKSSP + 7 * SP_PER_LINE + 2) -#define GFX_EM_GATE_4 (GFX_START_ROCKSSP + 7 * SP_PER_LINE + 3) -#define GFX_EM_GATE_1X (GFX_START_ROCKSSP + 7 * SP_PER_LINE + 4) -#define GFX_EM_GATE_2X (GFX_START_ROCKSSP + 7 * SP_PER_LINE + 5) -#define GFX_EM_GATE_3X (GFX_START_ROCKSSP + 7 * SP_PER_LINE + 6) -#define GFX_EM_GATE_4X (GFX_START_ROCKSSP + 7 * SP_PER_LINE + 7) - -#define GFX_MURPHY_GO_LEFT (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 8) -#define GFX_MURPHY_ANY_LEFT (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 9) -#define GFX_MURPHY_GO_RIGHT (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 11) -#define GFX_MURPHY_ANY_RIGHT (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 12) -#define GFX_MURPHY_SNAP_UP (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 14) -#define GFX_MURPHY_SNAP_DOWN (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 15) -#define GFX_MURPHY_SNAP_RIGHT (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 8) -#define GFX_MURPHY_SNAP_LEFT (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 9) -#define GFX_MURPHY_PUSH_RIGHT (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 10) -#define GFX_MURPHY_PUSH_LEFT (GFX_START_ROCKSSP + 1 * SP_PER_LINE + 11) - -#define GFX_SP_BUG_WARNING (GFX_START_ROCKSSP + 2 * SP_PER_LINE + 15) -#define GFX_SP_EXPLODE_EMPTY (GFX_START_ROCKSSP + 3 * SP_PER_LINE + 8) -#define GFX_SP_EXPLODE_INFOTRON (GFX_START_ROCKSSP + 4 * SP_PER_LINE + 8) -#define GFX_SP_BUG_ACTIVE (GFX_START_ROCKSSP + 6 * SP_PER_LINE + 8) -#define GFX_SP_SNIKSNAK_LEFT (GFX_START_ROCKSSP + 8 * SP_PER_LINE + 8) -#define GFX_SP_SNIKSNAK_RIGHT (GFX_START_ROCKSSP + 8 * SP_PER_LINE + 12) -#define GFX_SP_SNIKSNAK_UP (GFX_START_ROCKSSP + 9 * SP_PER_LINE + 8) -#define GFX_SP_SNIKSNAK_DOWN (GFX_START_ROCKSSP + 9 * SP_PER_LINE + 12) - -#define GFX2_SP_ELECTRON (GFX_START_ROCKSSP + 10 * SP_PER_LINE + 8) -#define GFX2_SP_TERMINAL (GFX_START_ROCKSSP + 11 * SP_PER_LINE + 8) -#define GFX2_SP_TERMINAL_ACTIVE (GFX_START_ROCKSSP + 12 * SP_PER_LINE + 8) - -#define GFX_SP_MURPHY_CLONE (GFX_START_ROCKSSP + 0 * SP_PER_LINE + 3) - -/* graphics from "RocksDC" */ -#define GFX_BELT1_MIDDLE (GFX_START_ROCKSDC + 0 * DC_PER_LINE + 0) -#define GFX_BELT1_LEFT (GFX_START_ROCKSDC + 1 * DC_PER_LINE + 0) -#define GFX_BELT1_RIGHT (GFX_START_ROCKSDC + 2 * DC_PER_LINE + 0) -#define GFX_BELT2_MIDDLE (GFX_START_ROCKSDC + 3 * DC_PER_LINE + 0) -#define GFX_BELT2_LEFT (GFX_START_ROCKSDC + 4 * DC_PER_LINE + 0) -#define GFX_BELT2_RIGHT (GFX_START_ROCKSDC + 5 * DC_PER_LINE + 0) -#define GFX_BELT3_MIDDLE (GFX_START_ROCKSDC + 6 * DC_PER_LINE + 0) -#define GFX_BELT3_LEFT (GFX_START_ROCKSDC + 7 * DC_PER_LINE + 0) -#define GFX_BELT3_RIGHT (GFX_START_ROCKSDC + 8 * DC_PER_LINE + 0) -#define GFX_BELT4_MIDDLE (GFX_START_ROCKSDC + 9 * DC_PER_LINE + 0) -#define GFX_BELT4_LEFT (GFX_START_ROCKSDC + 10 * DC_PER_LINE + 0) -#define GFX_BELT4_RIGHT (GFX_START_ROCKSDC + 11 * DC_PER_LINE + 0) -#define GFX_BELT1_SWITCH_LEFT (GFX_START_ROCKSDC + 12 * DC_PER_LINE + 0) -#define GFX_BELT2_SWITCH_LEFT (GFX_START_ROCKSDC + 12 * DC_PER_LINE + 1) -#define GFX_BELT3_SWITCH_LEFT (GFX_START_ROCKSDC + 12 * DC_PER_LINE + 2) -#define GFX_BELT4_SWITCH_LEFT (GFX_START_ROCKSDC + 12 * DC_PER_LINE + 3) -#define GFX_BELT1_SWITCH_MIDDLE (GFX_START_ROCKSDC + 13 * DC_PER_LINE + 0) -#define GFX_BELT2_SWITCH_MIDDLE (GFX_START_ROCKSDC + 13 * DC_PER_LINE + 1) -#define GFX_BELT3_SWITCH_MIDDLE (GFX_START_ROCKSDC + 13 * DC_PER_LINE + 2) -#define GFX_BELT4_SWITCH_MIDDLE (GFX_START_ROCKSDC + 13 * DC_PER_LINE + 3) -#define GFX_BELT1_SWITCH_RIGHT (GFX_START_ROCKSDC + 14 * DC_PER_LINE + 0) -#define GFX_BELT2_SWITCH_RIGHT (GFX_START_ROCKSDC + 14 * DC_PER_LINE + 1) -#define GFX_BELT3_SWITCH_RIGHT (GFX_START_ROCKSDC + 14 * DC_PER_LINE + 2) -#define GFX_BELT4_SWITCH_RIGHT (GFX_START_ROCKSDC + 14 * DC_PER_LINE + 3) - -#define GFX_SWITCHGATE_SWITCH_1 (GFX_START_ROCKSDC + 12 * DC_PER_LINE + 4) -#define GFX_SWITCHGATE_SWITCH_2 (GFX_START_ROCKSDC + 12 * DC_PER_LINE + 5) -#define GFX_LIGHT_SWITCH_OFF (GFX_START_ROCKSDC + 12 * DC_PER_LINE + 6) -#define GFX_LIGHT_SWITCH_ON (GFX_START_ROCKSDC + 12 * DC_PER_LINE + 7) -#define GFX_TIMEGATE_SWITCH (GFX_START_ROCKSDC + 15 * DC_PER_LINE + 0) - -#define GFX_ENVELOPE (GFX_START_ROCKSDC + 14 * DC_PER_LINE + 4) -#define GFX_SIGN_EXCLAMATION (GFX_START_ROCKSDC + 14 * DC_PER_LINE + 5) -#define GFX_SIGN_STOP (GFX_START_ROCKSDC + 14 * DC_PER_LINE + 6) -#define GFX_LANDMINE (GFX_START_ROCKSDC + 14 * DC_PER_LINE + 7) -#define GFX_STEEL_SLANTED (GFX_START_ROCKSDC + 15 * DC_PER_LINE + 5) - -#define GFX_EXTRA_TIME (GFX_START_ROCKSDC + 0 * DC_PER_LINE + 8) -#define GFX_SHIELD_ACTIVE (GFX_START_ROCKSDC + 1 * DC_PER_LINE + 8) -#define GFX_SHIELD_PASSIVE (GFX_START_ROCKSDC + 2 * DC_PER_LINE + 8) -#define GFX_MOLE_DOWN (GFX_START_ROCKSDC + 3 * DC_PER_LINE + 8) -#define GFX_MOLE_UP (GFX_START_ROCKSDC + 3 * DC_PER_LINE + 12) -#define GFX_MOLE_LEFT (GFX_START_ROCKSDC + 4 * DC_PER_LINE + 8) -#define GFX_MOLE_RIGHT (GFX_START_ROCKSDC + 4 * DC_PER_LINE + 12) -#define GFX_SWITCHGATE_CLOSED (GFX_START_ROCKSDC + 5 * DC_PER_LINE + 8) -#define GFX_SWITCHGATE_OPEN (GFX_START_ROCKSDC + 5 * DC_PER_LINE + 12) -#define GFX_TIMEGATE_CLOSED (GFX_START_ROCKSDC + 6 * DC_PER_LINE + 8) -#define GFX_TIMEGATE_OPEN (GFX_START_ROCKSDC + 6 * DC_PER_LINE + 12) -#define GFX_BALLOON_SEND_LEFT (GFX_START_ROCKSDC + 7 * DC_PER_LINE + 8) -#define GFX_BALLOON_SEND_RIGHT (GFX_START_ROCKSDC + 7 * DC_PER_LINE + 9) -#define GFX_BALLOON_SEND_UP (GFX_START_ROCKSDC + 7 * DC_PER_LINE + 10) -#define GFX_BALLOON_SEND_DOWN (GFX_START_ROCKSDC + 7 * DC_PER_LINE + 11) -#define GFX_BALLOON (GFX_START_ROCKSDC + 7 * DC_PER_LINE + 12) -#define GFX_BALLOON_SEND_ANY (GFX_START_ROCKSDC + 0 * DC_PER_LINE + 15) - -#define GFX_EMC_STEEL_WALL_1 (GFX_START_ROCKSDC + 0 * DC_PER_LINE + 14) -#define GFX_EMC_STEEL_WALL_2 (GFX_START_ROCKSDC + 0 * DC_PER_LINE + 14) -#define GFX_EMC_STEEL_WALL_3 (GFX_START_ROCKSDC + 0 * DC_PER_LINE + 14) -#define GFX_EMC_STEEL_WALL_4 (GFX_START_ROCKSDC + 0 * DC_PER_LINE + 14) -#define GFX_EMC_WALL_1 (GFX_START_ROCKSDC + 6 * DC_PER_LINE + 13) -#define GFX_EMC_WALL_2 (GFX_START_ROCKSDC + 6 * DC_PER_LINE + 14) -#define GFX_EMC_WALL_3 (GFX_START_ROCKSDC + 6 * DC_PER_LINE + 15) -#define GFX_EMC_WALL_4 (GFX_START_ROCKSDC + 1 * DC_PER_LINE + 14) -#define GFX_EMC_WALL_5 (GFX_START_ROCKSDC + 1 * DC_PER_LINE + 15) -#define GFX_EMC_WALL_6 (GFX_START_ROCKSDC + 2 * DC_PER_LINE + 14) -#define GFX_EMC_WALL_7 (GFX_START_ROCKSDC + 2 * DC_PER_LINE + 15) -#define GFX_EMC_WALL_8 (GFX_START_ROCKSDC + 1 * DC_PER_LINE + 14) - -/* graphics from "RocksMore" */ -#define GFX_ARROW_BLUE_LEFT (GFX_START_ROCKSMORE + 0 * MORE_PER_LINE + 0) -#define GFX_ARROW_BLUE_RIGHT (GFX_START_ROCKSMORE + 0 * MORE_PER_LINE + 1) -#define GFX_ARROW_BLUE_UP (GFX_START_ROCKSMORE + 0 * MORE_PER_LINE + 2) -#define GFX_ARROW_BLUE_DOWN (GFX_START_ROCKSMORE + 0 * MORE_PER_LINE + 3) -#define GFX_ARROW_RED_LEFT (GFX_START_ROCKSMORE + 1 * MORE_PER_LINE + 0) -#define GFX_ARROW_RED_RIGHT (GFX_START_ROCKSMORE + 1 * MORE_PER_LINE + 1) -#define GFX_ARROW_RED_UP (GFX_START_ROCKSMORE + 1 * MORE_PER_LINE + 2) -#define GFX_ARROW_RED_DOWN (GFX_START_ROCKSMORE + 1 * MORE_PER_LINE + 3) -#define GFX_SCROLLBAR_BLUE (GFX_START_ROCKSMORE + 2 * MORE_PER_LINE + 0) -#define GFX_SCROLLBAR_RED (GFX_START_ROCKSMORE + 2 * MORE_PER_LINE + 1) -#define GFX_PEARL (GFX_START_ROCKSMORE + 3 * MORE_PER_LINE + 0) -#define GFX_CRYSTAL (GFX_START_ROCKSMORE + 3 * MORE_PER_LINE + 1) -#define GFX_WALL_PEARL (GFX_START_ROCKSMORE + 3 * MORE_PER_LINE + 2) -#define GFX_WALL_CRYSTAL (GFX_START_ROCKSMORE + 3 * MORE_PER_LINE + 3) -#define GFX_PEARL_BREAKING (GFX_START_ROCKSMORE + 4 * MORE_PER_LINE + 0) -#define GFX_SPRING (GFX_START_ROCKSMORE + 5 * MORE_PER_LINE + 0) -#define GFX_TUBE_RIGHT_DOWN (GFX_START_ROCKSMORE + 5 * MORE_PER_LINE + 1) -#define GFX_TUBE_HORIZ_DOWN (GFX_START_ROCKSMORE + 5 * MORE_PER_LINE + 2) -#define GFX_TUBE_LEFT_DOWN (GFX_START_ROCKSMORE + 5 * MORE_PER_LINE + 3) -#define GFX_TUBE_HORIZONTAL (GFX_START_ROCKSMORE + 6 * MORE_PER_LINE + 0) -#define GFX_TUBE_VERT_RIGHT (GFX_START_ROCKSMORE + 6 * MORE_PER_LINE + 1) -#define GFX_TUBE_CROSS (GFX_START_ROCKSMORE + 6 * MORE_PER_LINE + 2) -#define GFX_TUBE_VERT_LEFT (GFX_START_ROCKSMORE + 6 * MORE_PER_LINE + 3) -#define GFX_TUBE_VERTICAL (GFX_START_ROCKSMORE + 7 * MORE_PER_LINE + 0) -#define GFX_TUBE_RIGHT_UP (GFX_START_ROCKSMORE + 7 * MORE_PER_LINE + 1) -#define GFX_TUBE_HORIZ_UP (GFX_START_ROCKSMORE + 7 * MORE_PER_LINE + 2) -#define GFX_TUBE_LEFT_UP (GFX_START_ROCKSMORE + 7 * MORE_PER_LINE + 3) - -#define GFX_TRAP_INACTIVE (GFX_START_ROCKSMORE + 0 * MORE_PER_LINE + 4) -#define GFX_TRAP_ACTIVE (GFX_START_ROCKSMORE + 0 * MORE_PER_LINE + 7) -#define GFX_BD_WALL (GFX_START_ROCKSMORE + 1 * MORE_PER_LINE + 4) -#define GFX_BD_ROCK (GFX_START_ROCKSMORE + 2 * MORE_PER_LINE + 4) -#define GFX_DX_SUPABOMB (GFX_START_ROCKSMORE + 1 * MORE_PER_LINE + 7) - -/* graphics from "RocksFont" */ -#define GFX_CHAR_START (GFX_START_ROCKSFONT) -#define GFX_CHAR_ASCII0 (GFX_CHAR_START - 32) -#define GFX_CHAR_AUSRUF (GFX_CHAR_ASCII0 + 33) -#define GFX_CHAR_ZOLL (GFX_CHAR_ASCII0 + 34) -#define GFX_CHAR_DOLLAR (GFX_CHAR_ASCII0 + 36) -#define GFX_CHAR_PROZ (GFX_CHAR_ASCII0 + 37) -#define GFX_CHAR_APOSTR (GFX_CHAR_ASCII0 + 39) -#define GFX_CHAR_KLAMM1 (GFX_CHAR_ASCII0 + 40) -#define GFX_CHAR_KLAMM2 (GFX_CHAR_ASCII0 + 41) -#define GFX_CHAR_PLUS (GFX_CHAR_ASCII0 + 43) -#define GFX_CHAR_KOMMA (GFX_CHAR_ASCII0 + 44) -#define GFX_CHAR_MINUS (GFX_CHAR_ASCII0 + 45) -#define GFX_CHAR_PUNKT (GFX_CHAR_ASCII0 + 46) -#define GFX_CHAR_SLASH (GFX_CHAR_ASCII0 + 47) -#define GFX_CHAR_0 (GFX_CHAR_ASCII0 + 48) -#define GFX_CHAR_9 (GFX_CHAR_ASCII0 + 57) -#define GFX_CHAR_DOPPEL (GFX_CHAR_ASCII0 + 58) -#define GFX_CHAR_SEMIKL (GFX_CHAR_ASCII0 + 59) -#define GFX_CHAR_LT (GFX_CHAR_ASCII0 + 60) -#define GFX_CHAR_GLEICH (GFX_CHAR_ASCII0 + 61) -#define GFX_CHAR_GT (GFX_CHAR_ASCII0 + 62) -#define GFX_CHAR_FRAGE (GFX_CHAR_ASCII0 + 63) -#define GFX_CHAR_AT (GFX_CHAR_ASCII0 + 64) -#define GFX_CHAR_A (GFX_CHAR_ASCII0 + 65) -#define GFX_CHAR_Z (GFX_CHAR_ASCII0 + 90) -#define GFX_CHAR_AE (GFX_CHAR_ASCII0 + 91) -#define GFX_CHAR_OE (GFX_CHAR_ASCII0 + 92) -#define GFX_CHAR_UE (GFX_CHAR_ASCII0 + 93) -#define GFX_CHAR_COPY (GFX_CHAR_ASCII0 + 94) -#define GFX_CHAR_END (GFX_CHAR_START + 79) - -/* new elements which still have no graphic */ -#define GFX_DOOR_WHITE GFX_CHAR_FRAGE -#define GFX_DOOR_WHITE_GRAY GFX_CHAR_FRAGE -#define GFX_KEY_WHITE GFX_CHAR_FRAGE -#define GFX_SIGN_RADIOACTIVITY GFX_CHAR_FRAGE -#define GFX_SIGN_WHEELCHAIR GFX_CHAR_FRAGE -#define GFX_SIGN_PARKING GFX_CHAR_FRAGE -#define GFX_SIGN_ONEWAY GFX_CHAR_FRAGE -#define GFX_SIGN_HEART GFX_CHAR_FRAGE -#define GFX_SIGN_TRIANGLE GFX_CHAR_FRAGE -#define GFX_SIGN_ROUND GFX_CHAR_FRAGE -#define GFX_SIGN_EXIT GFX_CHAR_FRAGE -#define GFX_SIGN_YINYANG GFX_CHAR_FRAGE -#define GFX_SIGN_OTHER GFX_CHAR_FRAGE -#define GFX_DX_UNKNOWN_15 GFX_CHAR_FRAGE -#define GFX_DX_UNKNOWN_42 GFX_CHAR_FRAGE - - -/* the names of the sounds */ -#define SND_AMOEBE 0 -#define SND_ANTIGRAV 1 -#define SND_AUTSCH 2 -#define SND_BLURB 3 -#define SND_BONG 4 -#define SND_BUING 5 -#define SND_DENG 6 -#define SND_FUEL 7 -#define SND_GONG 8 -#define SND_HALLOFFAME 9 -#define SND_HOLZ 10 -#define SND_HUI 11 -#define SND_KABUMM 12 -#define SND_KINK 13 -#define SND_KLAPPER 14 -#define SND_KLING 15 -#define SND_KLOPF 16 -#define SND_KLUMPF 17 -#define SND_KNACK 18 -#define SND_KNURK 19 -#define SND_KRACH 20 -#define SND_LACHEN 21 -#define SND_LASER 22 -#define SND_MIEP 23 -#define SND_NJAM 24 -#define SND_OEFFNEN 25 -#define SND_PLING 26 -#define SND_PONG 27 -#define SND_PUSCH 28 -#define SND_QUIEK 29 -#define SND_QUIRK 30 -#define SND_RHYTHMLOOP 31 -#define SND_ROAAAR 32 -#define SND_ROEHR 33 -#define SND_RUMMS 34 -#define SND_SCHLOPP 35 -#define SND_SCHLURF 36 -#define SND_SCHRFF 37 -#define SND_SCHWIRR 38 -#define SND_SIRR 39 -#define SND_SLURP 40 -#define SND_SPROING 41 -#define SND_WARNTON 42 -#define SND_WHOOSH 43 -#define SND_ZISCH 44 -#define SND_SP_BASE 45 -#define SND_SP_INFOTRON 46 -#define SND_SP_ZONKDOWN 47 -#define SND_SP_ZONKPUSH 48 -#define SND_SP_BUG 49 -#define SND_SP_BOOM 50 -#define SND_SP_BOOOM 51 -#define SND_SP_EXIT 52 -#define SND_EMPTY 53 -#define SND_GATE 54 - -#define NUM_SOUNDS 55 - - /* values for animation action types */ #define GFX_ACTION_DEFAULT 0 #define GFX_ACTION_WAITING 1 @@ -1738,10 +1127,7 @@ extern struct TapeInfo tape; extern struct GameInfo game; extern struct GlobalInfo global; extern struct ElementInfo element_info[]; -#if 0 -extern struct GraphicInfo graphic_info[]; -#endif -extern struct NewGraphicInfo new_graphic_info[]; +extern struct NewGraphicInfo graphic_info[]; extern struct ConfigInfo image_config[], sound_config[]; extern struct ConfigInfo image_config_suffix[], sound_config_suffix[]; extern struct FileInfo *image_files, *sound_files; diff --git a/src/screens.c b/src/screens.c index e86a4f12..09e068a3 100644 --- a/src/screens.c +++ b/src/screens.c @@ -135,7 +135,7 @@ static void ToggleFullscreenIfNeeded() setup.fullscreen = video.fullscreen_enabled; /* redraw background to newly created backbuffer */ - BlitBitmap(new_graphic_info[IMG_GLOBAL_BORDER].bitmap, backbuffer, + BlitBitmap(graphic_info[IMG_GLOBAL_BORDER].bitmap, backbuffer, 0,0, WIN_XSIZE,WIN_YSIZE, 0,0); /* restore old door content */ @@ -2899,12 +2899,12 @@ static void CreateScreenScrollbuttons() gfx_unpressed = scrollbutton_info[i].gfx_unpressed; gfx_pressed = scrollbutton_info[i].gfx_pressed; - gd_bitmap_unpressed = new_graphic_info[gfx_unpressed].bitmap; - gd_bitmap_pressed = new_graphic_info[gfx_pressed].bitmap; - gd_x1 = new_graphic_info[gfx_unpressed].src_x; - gd_y1 = new_graphic_info[gfx_unpressed].src_y; - gd_x2 = new_graphic_info[gfx_pressed].src_x; - gd_y2 = new_graphic_info[gfx_pressed].src_y; + gd_bitmap_unpressed = graphic_info[gfx_unpressed].bitmap; + gd_bitmap_pressed = graphic_info[gfx_pressed].bitmap; + gd_x1 = graphic_info[gfx_unpressed].src_x; + gd_y1 = graphic_info[gfx_unpressed].src_y; + gd_x2 = graphic_info[gfx_pressed].src_x; + gd_y2 = graphic_info[gfx_pressed].src_y; gi = CreateGadget(GDI_CUSTOM_ID, id, GDI_CUSTOM_TYPE_ID, i, @@ -2961,12 +2961,12 @@ static void CreateScreenScrollbars() #else gfx_unpressed = scrollbar_info[i].gfx_unpressed; gfx_pressed = scrollbar_info[i].gfx_pressed; - gd_bitmap_unpressed = new_graphic_info[gfx_unpressed].bitmap; - gd_bitmap_pressed = new_graphic_info[gfx_pressed].bitmap; - gd_x1 = new_graphic_info[gfx_unpressed].src_x; - gd_y1 = new_graphic_info[gfx_unpressed].src_y; - gd_x2 = new_graphic_info[gfx_pressed].src_x; - gd_y2 = new_graphic_info[gfx_pressed].src_y; + gd_bitmap_unpressed = graphic_info[gfx_unpressed].bitmap; + gd_bitmap_pressed = graphic_info[gfx_pressed].bitmap; + gd_x1 = graphic_info[gfx_unpressed].src_x; + gd_y1 = graphic_info[gfx_unpressed].src_y; + gd_x2 = graphic_info[gfx_pressed].src_x; + gd_y2 = graphic_info[gfx_pressed].src_y; #endif gi = CreateGadget(GDI_CUSTOM_ID, id, @@ -3006,14 +3006,14 @@ void CreateScreenGadgets() /* copy pointers to clip mask and GC */ scrollbar_bitmap[i]->clip_mask = - new_graphic_info[IMG_SCROLLBAR_BLUE + i].clip_mask; + graphic_info[IMG_SCROLLBAR_BLUE + i].clip_mask; scrollbar_bitmap[i]->stored_clip_gc = - new_graphic_info[IMG_SCROLLBAR_BLUE + i].clip_gc; + graphic_info[IMG_SCROLLBAR_BLUE + i].clip_gc; - BlitBitmap(new_graphic_info[IMG_SCROLLBAR_BLUE + i].bitmap, + BlitBitmap(graphic_info[IMG_SCROLLBAR_BLUE + i].bitmap, scrollbar_bitmap[i], - new_graphic_info[IMG_SCROLLBAR_BLUE + i].src_x, - new_graphic_info[IMG_SCROLLBAR_BLUE + i].src_y, + graphic_info[IMG_SCROLLBAR_BLUE + i].src_x, + graphic_info[IMG_SCROLLBAR_BLUE + i].src_y, TILEX, TILEY, 0, 0); } #endif diff --git a/src/tape.c b/src/tape.c index 7543d425..410ebb23 100644 --- a/src/tape.c +++ b/src/tape.c @@ -168,7 +168,7 @@ void DrawVideoDisplay(unsigned long state, unsigned long value) { int cx = DOOR_GFX_PAGEX3, cy = DOOR_GFX_PAGEY2; - BlitBitmap(new_graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, + BlitBitmap(graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, cx + VIDEO_REC_LABEL_XPOS, cy + VIDEO_REC_LABEL_YPOS, VIDEO_PBEND_LABEL_XSIZE, @@ -189,7 +189,7 @@ void DrawVideoDisplay(unsigned long state, unsigned long value) cx = DOOR_GFX_PAGEX3; /* i gerade => STATE_OFF / PRESS_ON */ if (video_pos[pos][part_label][0] && value != VIDEO_DISPLAY_SYMBOL_ONLY) - BlitBitmap(new_graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, + BlitBitmap(graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, cx + video_pos[pos][part_label][xpos], cy + video_pos[pos][part_label][ypos], video_pos[pos][part_label][xsize], @@ -197,7 +197,7 @@ void DrawVideoDisplay(unsigned long state, unsigned long value) VX + video_pos[pos][part_label][xpos], VY + video_pos[pos][part_label][ypos]); if (video_pos[pos][part_symbol][0] && value != VIDEO_DISPLAY_LABEL_ONLY) - BlitBitmap(new_graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, + BlitBitmap(graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, cx + video_pos[pos][part_symbol][xpos], cy + video_pos[pos][part_symbol][ypos], video_pos[pos][part_symbol][xsize], @@ -211,7 +211,7 @@ void DrawVideoDisplay(unsigned long state, unsigned long value) { int cx = DOOR_GFX_PAGEX4, cy = DOOR_GFX_PAGEY2; - BlitBitmap(new_graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, + BlitBitmap(graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, cx + VIDEO_PLAY_SYMBOL_XPOS, cy + VIDEO_PLAY_SYMBOL_YPOS, VIDEO_PLAY_SYMBOL_XSIZE - 2, @@ -224,7 +224,7 @@ void DrawVideoDisplay(unsigned long state, unsigned long value) { int cx = DOOR_GFX_PAGEX6, cy = DOOR_GFX_PAGEY1; - BlitBitmap(new_graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, + BlitBitmap(graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, cx + VIDEO_PBEND_LABEL_XPOS, cy + VIDEO_PBEND_LABEL_YPOS, VIDEO_PBEND_LABEL_XSIZE, @@ -268,10 +268,10 @@ void DrawVideoDisplay(unsigned long state, unsigned long value) void DrawCompleteVideoDisplay() { - BlitBitmap(new_graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, + BlitBitmap(graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, DOOR_GFX_PAGEX3, DOOR_GFX_PAGEY2, gfx.vxsize, gfx.vysize, gfx.vx, gfx.vy); - BlitBitmap(new_graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, + BlitBitmap(graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, DOOR_GFX_PAGEX4 + VIDEO_CONTROL_XPOS, DOOR_GFX_PAGEY2 + VIDEO_CONTROL_YPOS, VIDEO_CONTROL_XSIZE, VIDEO_CONTROL_YSIZE, @@ -857,7 +857,7 @@ void CreateTapeButtons() for (i=0; i= 0 && graphic_info[graphic].bitmap != NULL) - { - *bitmap = graphic_info[graphic].bitmap; - *x = graphic_info[graphic].src_x; - *y = graphic_info[graphic].src_y; - } - else if (graphic >= GFX_START_ROCKSELEMENTS && - graphic <= GFX_END_ROCKSELEMENTS) - { - graphic -= GFX_START_ROCKSELEMENTS; - *bitmap = new_graphic_info[IMG_OLD_PIX_ELEMENTS].bitmap; - *x = (graphic % GFX_PER_LINE) * TILEX; - *y = (graphic / GFX_PER_LINE) * TILEY; - } - else if (graphic >= GFX_START_ROCKSHEROES && graphic <= GFX_END_ROCKSHEROES) - { - graphic -= GFX_START_ROCKSHEROES; - *bitmap = new_graphic_info[IMG_OLD_PIX_HEROES].bitmap; - *x = (graphic % HEROES_PER_LINE) * TILEX; - *y = (graphic / HEROES_PER_LINE) * TILEY; - } - else if (graphic >= GFX_START_ROCKSSP && graphic <= GFX_END_ROCKSSP) - { - graphic -= GFX_START_ROCKSSP; - *bitmap = new_graphic_info[IMG_OLD_PIX_SP].bitmap; - *x = (graphic % SP_PER_LINE) * TILEX; - *y = (graphic / SP_PER_LINE) * TILEY; - } - else if (graphic >= GFX_START_ROCKSDC && graphic <= GFX_END_ROCKSDC) - { - graphic -= GFX_START_ROCKSDC; - *bitmap = new_graphic_info[IMG_OLD_PIX_DC].bitmap; - *x = (graphic % DC_PER_LINE) * TILEX; - *y = (graphic / DC_PER_LINE) * TILEY; - } - else if (graphic >= GFX_START_ROCKSMORE && graphic <= GFX_END_ROCKSMORE) - { - graphic -= GFX_START_ROCKSMORE; - *bitmap = new_graphic_info[IMG_OLD_PIX_MORE].bitmap; - *x = (graphic % MORE_PER_LINE) * TILEX; - *y = (graphic / MORE_PER_LINE) * TILEY; - } - else if (graphic >= GFX_START_ROCKSFONT && graphic <= GFX_END_ROCKSFONT) - { - graphic -= GFX_START_ROCKSFONT; - *bitmap = new_graphic_info[IMG_OLD_PIX_FONT_EM].bitmap; - *x = (graphic % FONT_CHARS_PER_LINE) * TILEX; - *y = (graphic / FONT_CHARS_PER_LINE) * TILEY; - } - else - { - *bitmap = new_graphic_info[IMG_OLD_PIX_SP].bitmap; - *x = 0; - *y = 0; - } -} -#endif - void getGraphicSource(int graphic, int frame, Bitmap **bitmap, int *x, int *y) { - Bitmap *src_bitmap = new_graphic_info[graphic].bitmap; - int offset_x = new_graphic_info[graphic].offset_x; - int offset_y = new_graphic_info[graphic].offset_y; - int src_x = new_graphic_info[graphic].src_x + frame * offset_x; - int src_y = new_graphic_info[graphic].src_y + frame * offset_y; + Bitmap *src_bitmap = graphic_info[graphic].bitmap; + int offset_x = graphic_info[graphic].offset_x; + int offset_y = graphic_info[graphic].offset_y; + int src_x = graphic_info[graphic].src_x + frame * offset_x; + int src_y = graphic_info[graphic].src_y + frame * offset_y; *bitmap = src_bitmap; *x = src_x; @@ -952,11 +891,11 @@ void DrawGraphicExt(DrawBuffer *dst_bitmap, int x, int y, int graphic, getGraphicSource(graphic, frame, &src_bitmap, &src_x, &src_y); #else - Bitmap *src_bitmap = new_graphic_info[graphic].bitmap; - int src_x = new_graphic_info[graphic].src_x; - int src_y = new_graphic_info[graphic].src_y; - int offset_x = new_graphic_info[graphic].offset_x; - int offset_y = new_graphic_info[graphic].offset_y; + Bitmap *src_bitmap = graphic_info[graphic].bitmap; + int src_x = graphic_info[graphic].src_x; + int src_y = graphic_info[graphic].src_y; + int offset_x = graphic_info[graphic].offset_x; + int offset_y = graphic_info[graphic].offset_y; src_x += frame * offset_x; src_y += frame * offset_y; @@ -993,11 +932,11 @@ void DrawGraphicThruMaskExt(DrawBuffer *d, int dest_x, int dest_y, int graphic, drawing_gc = src_bitmap->stored_clip_gc; #else GC drawing_gc = src_bitmap->stored_clip_gc; - Bitmap *src_bitmap = new_graphic_info[graphic].bitmap; - int src_x = new_graphic_info[graphic].src_x; - int src_y = new_graphic_info[graphic].src_y; - int offset_x = new_graphic_info[graphic].offset_x; - int offset_y = new_graphic_info[graphic].offset_y; + Bitmap *src_bitmap = graphic_info[graphic].bitmap; + int src_x = graphic_info[graphic].src_x; + int src_y = graphic_info[graphic].src_y; + int offset_x = graphic_info[graphic].offset_x; + int offset_y = graphic_info[graphic].offset_y; src_x += frame * offset_x; src_y += frame * offset_y; @@ -1016,11 +955,11 @@ void DrawMiniGraphic(int x, int y, int graphic) void getMiniGraphicSource(int graphic, Bitmap **bitmap, int *x, int *y) { - Bitmap *src_bitmap = new_graphic_info[graphic].bitmap; + Bitmap *src_bitmap = graphic_info[graphic].bitmap; int mini_startx = 0; int mini_starty = src_bitmap->height * 2 / 3; - int src_x = mini_startx + new_graphic_info[graphic].src_x / 2; - int src_y = mini_starty + new_graphic_info[graphic].src_y / 2; + int src_x = mini_startx + graphic_info[graphic].src_x / 2; + int src_y = mini_starty + graphic_info[graphic].src_y / 2; if (src_x + MINI_TILEX > src_bitmap->width || src_y + MINI_TILEY > src_bitmap->height) @@ -1131,11 +1070,11 @@ void DrawGraphicShifted(int x,int y, int dx,int dy, int graphic, int frame, MarkTileDirty(x, y + SIGN(dy)); } - src_bitmap = new_graphic_info[graphic].bitmap; - src_x = new_graphic_info[graphic].src_x; - src_y = new_graphic_info[graphic].src_y; - offset_x = new_graphic_info[graphic].offset_x; - offset_y = new_graphic_info[graphic].offset_y; + src_bitmap = graphic_info[graphic].bitmap; + src_x = graphic_info[graphic].src_x; + src_y = graphic_info[graphic].src_y; + offset_x = graphic_info[graphic].offset_x; + offset_y = graphic_info[graphic].offset_y; drawing_gc = src_bitmap->stored_clip_gc; @@ -1176,157 +1115,6 @@ void DrawGraphicShiftedThruMask(int x,int y, int dx,int dy, int graphic, DrawGraphicShifted(x,y, dx,dy, graphic, frame, cut_mode, USE_MASKING); } -#if 0 -void DrawScreenElementExt(int x, int y, int dx, int dy, int element, - int cut_mode, int mask_mode) -{ - int ux = LEVELX(x), uy = LEVELY(y); - int graphic = el2gfx(element); - int phase8 = ABS(MovPos[ux][uy]) / (TILEX / 8); - int phase4 = phase8 / 2; - int phase2 = phase8 / 4; - int dir = MovDir[ux][uy]; - - if (element == EL_PACMAN || element == EL_BUG || element == EL_SPACESHIP) - { - graphic += 1 * !phase2; - - if (dir == MV_UP) - graphic += 1 * 2; - else if (dir == MV_LEFT) - graphic += 2 * 2; - else if (dir == MV_DOWN) - graphic += 3 * 2; - } - else if (element == EL_SP_SNIKSNAK) - { - if (dir == MV_LEFT) - graphic = GFX_SP_SNIKSNAK_LEFT; - else if (dir == MV_RIGHT) - graphic = GFX_SP_SNIKSNAK_RIGHT; - else if (dir == MV_UP) - graphic = GFX_SP_SNIKSNAK_UP; - else - graphic = GFX_SP_SNIKSNAK_DOWN; - - graphic += (phase8 < 4 ? phase8 : 7 - phase8); - } - else if (element == EL_SP_ELECTRON) - { - graphic = GFX2_SP_ELECTRON + getGraphicAnimationPhase(8, 2, ANIM_LOOP); - } - else if (element == EL_MOLE || element == EL_PENGUIN || - element == EL_PIG || element == EL_DRAGON) - { - if (dir == MV_LEFT) - graphic = (element == EL_MOLE ? GFX_MOLE_LEFT : - element == EL_PENGUIN ? GFX_PINGUIN_LEFT : - element == EL_PIG ? GFX_SCHWEIN_LEFT : GFX_DRACHE_LEFT); - else if (dir == MV_RIGHT) - graphic = (element == EL_MOLE ? GFX_MOLE_RIGHT : - element == EL_PENGUIN ? GFX_PINGUIN_RIGHT : - element == EL_PIG ? GFX_SCHWEIN_RIGHT : GFX_DRACHE_RIGHT); - else if (dir == MV_UP) - graphic = (element == EL_MOLE ? GFX_MOLE_UP : - element == EL_PENGUIN ? GFX_PINGUIN_UP : - element == EL_PIG ? GFX_SCHWEIN_UP : GFX_DRACHE_UP); - else - graphic = (element == EL_MOLE ? GFX_MOLE_DOWN : - element == EL_PENGUIN ? GFX_PINGUIN_DOWN : - element == EL_PIG ? GFX_SCHWEIN_DOWN : GFX_DRACHE_DOWN); - - graphic += phase4; - } - else if (element == EL_SATELLITE) - { - graphic = GFX_SONDE_START + getGraphicAnimationPhase(8, 2, ANIM_LOOP); - } - else if (element == EL_ACID) - { - graphic = GFX_GEBLUBBER + getGraphicAnimationPhase(4, 10, ANIM_LOOP); - } - else if (element == EL_BD_BUTTERFLY || element == EL_BD_FIREFLY) - { - graphic += !phase2; - } - else if (element == EL_BALLOON) - { - graphic += phase4; - } - else if ((element == EL_ROCK || - element == EL_SP_ZONK || - element == EL_BD_ROCK || - element == EL_SP_INFOTRON || - IS_GEM(element)) - && !cut_mode) - { - if (uy >= lev_fieldy-1 || !IS_BELT(Feld[ux][uy+1])) - { - if (element == EL_ROCK || - element == EL_SP_ZONK || - element == EL_BD_ROCK) - { - if (dir == MV_LEFT) - graphic += (4 - phase4) % 4; - else if (dir == MV_RIGHT) - graphic += phase4; - else - graphic += phase2 * 2; - } - else if (element != EL_SP_INFOTRON) - graphic += phase2; - } - } - else if (element == EL_MAGIC_WALL_ACTIVE || - element == EL_MAGIC_WALL_EMPTYING || - element == EL_BD_MAGIC_WALL_ACTIVE || - element == EL_BD_MAGIC_WALL_EMPTYING || - element == EL_MAGIC_WALL_FULL || - element == EL_BD_MAGIC_WALL_FULL) - { - graphic += 3 + getGraphicAnimationPhase(4, 4, ANIM_REVERSE); - } - else if (IS_AMOEBOID(element) || element == EL_AMOEBA_DRIPPING) - { - graphic = (element == EL_AMOEBA_DEAD ? GFX_AMOEBE_TOT : GFX_AMOEBE_LEBT); - graphic += (x + 2 * y + 4) % 4; - } - else if (element == EL_WALL_GROWING) - { - boolean links_massiv = FALSE, rechts_massiv = FALSE; - - if (!IN_LEV_FIELD(ux-1, uy) || IS_MAUER(Feld[ux-1][uy])) - links_massiv = TRUE; - if (!IN_LEV_FIELD(ux+1, uy) || IS_MAUER(Feld[ux+1][uy])) - rechts_massiv = TRUE; - - if (links_massiv && rechts_massiv) - graphic = GFX_MAUERWERK; - else if (links_massiv) - graphic = GFX_MAUER_R; - else if (rechts_massiv) - graphic = GFX_MAUER_L; - } -#if 0 - else if ((element == EL_INVISIBLE_STEELWALL || - element == EL_INVISIBLE_WALL || - element == EL_INVISIBLE_SAND) && game.light_time_left) - { - graphic = (element == EL_INVISIBLE_STEELWALL ? GFX_INVISIBLE_STEEL_ON : - element == EL_INVISIBLE_WALL ? GFX_UNSICHTBAR_ON : - GFX_SAND_INVISIBLE_ON); - } -#endif - - if (dx || dy) - DrawGraphicShifted(x, y, dx, dy, graphic, cut_mode, mask_mode); - else if (mask_mode == USE_MASKING) - DrawGraphicThruMask(x, y, graphic); - else - DrawGraphic(x, y, graphic); -} -#endif - inline static int getFramePosition(int x, int y) { int frame_pos = -1; /* default: global synchronization */ @@ -1408,12 +1196,12 @@ void DrawScreenElementExt(int x, int y, int dx, int dy, int element, else if (left_stopped) { graphic = IMG_WALL_GROWING_ACTIVE_RIGHT; - frame = new_graphic_info[graphic].anim_frames - 1; + frame = graphic_info[graphic].anim_frames - 1; } else if (right_stopped) { graphic = IMG_WALL_GROWING_ACTIVE_LEFT; - frame = new_graphic_info[graphic].anim_frames - 1; + frame = graphic_info[graphic].anim_frames - 1; } } else if (IS_AMOEBOID(element) || element == EL_AMOEBA_DRIPPING) @@ -1508,9 +1296,9 @@ void DrawCrumbledSand(int x, int y) graphic = IMG_SAND_CRUMBLED; - src_bitmap = new_graphic_info[graphic].bitmap; - src_x = new_graphic_info[graphic].src_x; - src_y = new_graphic_info[graphic].src_y; + src_bitmap = graphic_info[graphic].bitmap; + src_x = graphic_info[graphic].src_x; + src_y = graphic_info[graphic].src_y; for(i=0; i<4; i++) { @@ -1554,9 +1342,9 @@ void DrawCrumbledSand(int x, int y) { graphic = IMG_SAND_CRUMBLED; - src_bitmap = new_graphic_info[graphic].bitmap; - src_x = new_graphic_info[graphic].src_x; - src_y = new_graphic_info[graphic].src_y; + src_bitmap = graphic_info[graphic].bitmap; + src_x = graphic_info[graphic].src_x; + src_y = graphic_info[graphic].src_y; for(i=0; i<4; i++) { @@ -1766,11 +1554,11 @@ void DrawMiniElementOrWall(int sx, int sy, int scroll_x, int scroll_y) void getMicroGraphicSource(int graphic, Bitmap **bitmap, int *x, int *y) { - Bitmap *src_bitmap = new_graphic_info[graphic].bitmap; + Bitmap *src_bitmap = graphic_info[graphic].bitmap; int mini_startx = src_bitmap->width * 3 / 4; int mini_starty = src_bitmap->height * 2 / 3; - int src_x = mini_startx + new_graphic_info[graphic].src_x / 8; - int src_y = mini_starty + new_graphic_info[graphic].src_y / 8; + int src_x = mini_startx + graphic_info[graphic].src_x / 8; + int src_y = mini_starty + graphic_info[graphic].src_y / 8; if (src_x + MICRO_TILEX > src_bitmap->width || src_y + MICRO_TILEY > src_bitmap->height) @@ -2352,7 +2140,7 @@ unsigned int MoveDoor(unsigned int door_state) for(x=start; x<=DXSIZE; x+=stepsize) { - Bitmap *bitmap = new_graphic_info[IMG_GLOBAL_DOOR].bitmap; + Bitmap *bitmap = graphic_info[IMG_GLOBAL_DOOR].bitmap; GC gc = bitmap->stored_clip_gc; if (!(door_state & DOOR_NO_DELAY)) @@ -2458,10 +2246,10 @@ unsigned int MoveDoor(unsigned int door_state) void DrawSpecialEditorDoor() { /* draw bigger toolbox window */ - BlitBitmap(new_graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, + BlitBitmap(graphic_info[IMG_GLOBAL_DOOR].bitmap, drawto, DOOR_GFX_PAGEX7, 0, EXSIZE + 8, 8, EX - 4, EY - 12); - BlitBitmap(new_graphic_info[IMG_GLOBAL_BORDER].bitmap, drawto, + BlitBitmap(graphic_info[IMG_GLOBAL_BORDER].bitmap, drawto, EX - 4, VY - 4, EXSIZE + 8, EYSIZE - VYSIZE + 4, EX - 4, EY - 4); @@ -2471,7 +2259,7 @@ void DrawSpecialEditorDoor() void UndrawSpecialEditorDoor() { /* draw normal tape recorder window */ - BlitBitmap(new_graphic_info[IMG_GLOBAL_BORDER].bitmap, drawto, + BlitBitmap(graphic_info[IMG_GLOBAL_BORDER].bitmap, drawto, EX - 4, EY - 12, EXSIZE + 8, EYSIZE - VYSIZE + 12, EX - 4, EY - 12); @@ -2601,7 +2389,7 @@ void CreateToolButtons() for (i=0; i= EL_SP_START && element <= EL_SP_END) - { - int nr_element = element - EL_SP_START; - int gfx_per_line = 8; - int nr_graphic = - (nr_element / gfx_per_line) * SP_PER_LINE + - (nr_element % gfx_per_line); - - return GFX_START_ROCKSSP + nr_graphic; - } - else - return -1; - } - } -} - -int el2gfx(int element) -{ -#if 1 - int graphic_OLD = el2gfx_OLD(element); - - return graphic_OLD; -#else - - int graphic_NEW = element_info[element].graphic[GFX_ACTION_DEFAULT]; - -#if DEBUG - int graphic_OLD = el2gfx_OLD(element); - - if (element >= MAX_NUM_ELEMENTS) - { - Error(ERR_WARN, "el2gfx: element == %d >= MAX_NUM_ELEMENTS", element); - } - - if (graphic_NEW != graphic_OLD) - { - Error(ERR_WARN, "el2gfx: graphic_NEW (%d) != graphic_OLD (%d)", - graphic_NEW, graphic_OLD); - } -#endif - - return graphic_NEW; -#endif -} - int el2img(int element) { int graphic = element_info[element].graphic[GFX_ACTION_DEFAULT]; diff --git a/src/tools.h b/src/tools.h index f5ed62f7..63523b49 100644 --- a/src/tools.h +++ b/src/tools.h @@ -132,7 +132,6 @@ void CreateToolButtons(); void FreeToolButtons(); int get_next_element(int); -int el2gfx(int); int el2img(int); int el_dir2img(int, int); int el_dir_act2img(int, int, int);