rnd-20030208-2-src
[rocksndiamonds.git] / src / tools.c
index f41affe9cdab8bc4f225d23d74e11f4970c2e41b..b20e04cb85ef05904d15107494bb2b9f59a54ce9 100644 (file)
@@ -959,16 +959,22 @@ void getMiniGraphicSource(int graphic, Bitmap **bitmap, int *x, int *y)
   int src_x = mini_startx + graphic_info[graphic].src_x / 2;
   int src_y = mini_starty + graphic_info[graphic].src_y / 2;
 
+#if 0
+  /* !!! not needed anymore, because of automatically created mini graphics */
   if (src_x + MINI_TILEX > src_bitmap->width ||
       src_y + MINI_TILEY > src_bitmap->height)
   {
     /* graphic of desired size seems not to be contained in this image;
        dirty workaround: get it from the middle of the normal sized image */
 
+    printf("::: using dirty workaround for %d (%d, %d)\n",
+          graphic, src_bitmap->width, src_bitmap->height);
+
     getGraphicSource(graphic, 0, &src_bitmap, &src_x, &src_y);
     src_x += (TILEX / 2 - MINI_TILEX / 2);
     src_y += (TILEY / 2 - MINI_TILEY / 2);
   }
+#endif
 
   *bitmap = src_bitmap;
   *x = src_x;
@@ -1155,6 +1161,7 @@ void DrawScreenElementExt(int x, int y, int dx, int dy, int element,
       frame = graphic_info[graphic].anim_frames - 1;
     }
   }
+#if 0
   else if (IS_AMOEBOID(element) || element == EL_AMOEBA_DRIPPING)
   {
     graphic = (element == EL_BD_AMOEBA ? IMG_BD_AMOEBA_PART1 :
@@ -1165,6 +1172,16 @@ void DrawScreenElementExt(int x, int y, int dx, int dy, int element,
 
     graphic += (x + 2 * y + 4) % 4;
   }
+#endif
+
+#if 0
+  if (IS_AMOEBOID(element) || element == EL_AMOEBA_DRIPPING)
+  {
+    if (Feld[lx][ly] == EL_AMOEBA_DRIPPING)
+      printf("---> %d -> %d / %d [%d]\n",
+            element, graphic, frame, GfxRandom[lx][ly]);
+  }
+#endif
 
   if (dx || dy)
     DrawGraphicShifted(x, y, dx, dy, graphic, frame, cut_mode, mask_mode);