rnd-20070413-1-src
authorHolger Schemel <info@artsoft.org>
Fri, 13 Apr 2007 20:10:37 +0000 (22:10 +0200)
committerHolger Schemel <info@artsoft.org>
Sat, 30 Aug 2014 08:55:35 +0000 (10:55 +0200)
src/conf_gfx.c
src/conf_var.c
src/conftime.h
src/game.c
src/game.h
src/main.h

index 7179170135292bb17ab002bdc2ec46292df25688..640cb4e0d6321b21b3f9ec5d7a786008cb9fdbd3 100644 (file)
@@ -5928,51 +5928,123 @@ struct ConfigInfo image_config[] =
   { "game.panel.element_1.x",                  "-1"                    },
   { "game.panel.element_1.y",                  "-1"                    },
   { "game.panel.element_1.tile_size",          "16"                    },
-  { "game.panel.element_1.element",            "custom_1"              },
+  { "game.panel.element_1.element",            "empty_space"           },
   { "game.panel.element_1.draw_masked",                "false"                 },
   { "game.panel.element_1.draw_order",         "0"                     },
+  { "game.panel.element_1_count.x",            "-1"                    },
+  { "game.panel.element_1_count.y",            "-1"                    },
+  { "game.panel.element_1_count.align",                "left"                  },
+  { "game.panel.element_1_count.valign",       "top"                   },
+  { "game.panel.element_1_count.digits",       "-1"                    },
+  { "game.panel.element_1_count.font",         "font.text_2"           },
+  { "game.panel.element_1_count.element",      "empty_space"           },
+  { "game.panel.element_1_count.draw_masked",  "true"                  },
+  { "game.panel.element_1_count.draw_order",   "0"                     },
   { "game.panel.element_2.x",                  "-1"                    },
   { "game.panel.element_2.y",                  "-1"                    },
   { "game.panel.element_2.tile_size",          "16"                    },
-  { "game.panel.element_2.element",            "custom_1"              },
+  { "game.panel.element_2.element",            "empty_space"           },
   { "game.panel.element_2.draw_masked",                "false"                 },
   { "game.panel.element_2.draw_order",         "0"                     },
+  { "game.panel.element_2_count.x",            "-1"                    },
+  { "game.panel.element_2_count.y",            "-1"                    },
+  { "game.panel.element_2_count.align",                "left"                  },
+  { "game.panel.element_2_count.valign",       "top"                   },
+  { "game.panel.element_2_count.digits",       "-1"                    },
+  { "game.panel.element_2_count.font",         "font.text_2"           },
+  { "game.panel.element_2_count.element",      "empty_space"           },
+  { "game.panel.element_2_count.draw_masked",  "true"                  },
+  { "game.panel.element_2_count.draw_order",   "0"                     },
   { "game.panel.element_3.x",                  "-1"                    },
   { "game.panel.element_3.y",                  "-1"                    },
   { "game.panel.element_3.tile_size",          "16"                    },
-  { "game.panel.element_3.element",            "custom_1"              },
+  { "game.panel.element_3.element",            "empty_space"           },
   { "game.panel.element_3.draw_masked",                "false"                 },
   { "game.panel.element_3.draw_order",         "0"                     },
+  { "game.panel.element_3_count.x",            "-1"                    },
+  { "game.panel.element_3_count.y",            "-1"                    },
+  { "game.panel.element_3_count.align",                "left"                  },
+  { "game.panel.element_3_count.valign",       "top"                   },
+  { "game.panel.element_3_count.digits",       "-1"                    },
+  { "game.panel.element_3_count.font",         "font.text_2"           },
+  { "game.panel.element_3_count.element",      "empty_space"           },
+  { "game.panel.element_3_count.draw_masked",  "true"                  },
+  { "game.panel.element_3_count.draw_order",   "0"                     },
   { "game.panel.element_4.x",                  "-1"                    },
   { "game.panel.element_4.y",                  "-1"                    },
   { "game.panel.element_4.tile_size",          "16"                    },
-  { "game.panel.element_4.element",            "custom_1"              },
+  { "game.panel.element_4.element",            "empty_space"           },
   { "game.panel.element_4.draw_masked",                "false"                 },
   { "game.panel.element_4.draw_order",         "0"                     },
+  { "game.panel.element_4_count.x",            "-1"                    },
+  { "game.panel.element_4_count.y",            "-1"                    },
+  { "game.panel.element_4_count.align",                "left"                  },
+  { "game.panel.element_4_count.valign",       "top"                   },
+  { "game.panel.element_4_count.digits",       "-1"                    },
+  { "game.panel.element_4_count.font",         "font.text_2"           },
+  { "game.panel.element_4_count.element",      "empty_space"           },
+  { "game.panel.element_4_count.draw_masked",  "true"                  },
+  { "game.panel.element_4_count.draw_order",   "0"                     },
   { "game.panel.element_5.x",                  "-1"                    },
   { "game.panel.element_5.y",                  "-1"                    },
   { "game.panel.element_5.tile_size",          "16"                    },
-  { "game.panel.element_5.element",            "custom_1"              },
+  { "game.panel.element_5.element",            "empty_space"           },
   { "game.panel.element_5.draw_masked",                "false"                 },
   { "game.panel.element_5.draw_order",         "0"                     },
+  { "game.panel.element_5_count.x",            "-1"                    },
+  { "game.panel.element_5_count.y",            "-1"                    },
+  { "game.panel.element_5_count.align",                "left"                  },
+  { "game.panel.element_5_count.valign",       "top"                   },
+  { "game.panel.element_5_count.digits",       "-1"                    },
+  { "game.panel.element_5_count.font",         "font.text_2"           },
+  { "game.panel.element_5_count.element",      "empty_space"           },
+  { "game.panel.element_5_count.draw_masked",  "true"                  },
+  { "game.panel.element_5_count.draw_order",   "0"                     },
   { "game.panel.element_6.x",                  "-1"                    },
   { "game.panel.element_6.y",                  "-1"                    },
   { "game.panel.element_6.tile_size",          "16"                    },
-  { "game.panel.element_6.element",            "custom_1"              },
+  { "game.panel.element_6.element",            "empty_space"           },
   { "game.panel.element_6.draw_masked",                "false"                 },
   { "game.panel.element_6.draw_order",         "0"                     },
+  { "game.panel.element_6_count.x",            "-1"                    },
+  { "game.panel.element_6_count.y",            "-1"                    },
+  { "game.panel.element_6_count.align",                "left"                  },
+  { "game.panel.element_6_count.valign",       "top"                   },
+  { "game.panel.element_6_count.digits",       "-1"                    },
+  { "game.panel.element_6_count.font",         "font.text_2"           },
+  { "game.panel.element_6_count.element",      "empty_space"           },
+  { "game.panel.element_6_count.draw_masked",  "true"                  },
+  { "game.panel.element_6_count.draw_order",   "0"                     },
   { "game.panel.element_7.x",                  "-1"                    },
   { "game.panel.element_7.y",                  "-1"                    },
   { "game.panel.element_7.tile_size",          "16"                    },
-  { "game.panel.element_7.element",            "custom_1"              },
+  { "game.panel.element_7.element",            "empty_space"           },
   { "game.panel.element_7.draw_masked",                "false"                 },
   { "game.panel.element_7.draw_order",         "0"                     },
+  { "game.panel.element_7_count.x",            "-1"                    },
+  { "game.panel.element_7_count.y",            "-1"                    },
+  { "game.panel.element_7_count.align",                "left"                  },
+  { "game.panel.element_7_count.valign",       "top"                   },
+  { "game.panel.element_7_count.digits",       "-1"                    },
+  { "game.panel.element_7_count.font",         "font.text_2"           },
+  { "game.panel.element_7_count.element",      "empty_space"           },
+  { "game.panel.element_7_count.draw_masked",  "true"                  },
+  { "game.panel.element_7_count.draw_order",   "0"                     },
   { "game.panel.element_8.x",                  "-1"                    },
   { "game.panel.element_8.y",                  "-1"                    },
   { "game.panel.element_8.tile_size",          "16"                    },
-  { "game.panel.element_8.element",            "custom_1"              },
+  { "game.panel.element_8.element",            "empty_space"           },
   { "game.panel.element_8.draw_masked",                "false"                 },
   { "game.panel.element_8.draw_order",         "0"                     },
+  { "game.panel.element_8_count.x",            "-1"                    },
+  { "game.panel.element_8_count.y",            "-1"                    },
+  { "game.panel.element_8_count.align",                "left"                  },
+  { "game.panel.element_8_count.valign",       "top"                   },
+  { "game.panel.element_8_count.digits",       "-1"                    },
+  { "game.panel.element_8_count.font",         "font.text_2"           },
+  { "game.panel.element_8_count.element",      "empty_space"           },
+  { "game.panel.element_8_count.draw_masked",  "true"                  },
+  { "game.panel.element_8_count.draw_order",   "0"                     },
 
   { "game.panel.ce_score_1.x",                 "-1"                    },
   { "game.panel.ce_score_1.y",                 "-1"                    },
@@ -5980,13 +6052,13 @@ struct ConfigInfo image_config[] =
   { "game.panel.ce_score_1.valign",            "top"                   },
   { "game.panel.ce_score_1.digits",            "-1"                    },
   { "game.panel.ce_score_1.font",              "font.text_2"           },
-  { "game.panel.ce_score_1.element",           "custom_1"              },
+  { "game.panel.ce_score_1.element",           "empty_space"           },
   { "game.panel.ce_score_1.draw_masked",       "true"                  },
   { "game.panel.ce_score_1.draw_order",                "0"                     },
   { "game.panel.ce_score_1_element.x",         "-1"                    },
   { "game.panel.ce_score_1_element.y",         "-1"                    },
   { "game.panel.ce_score_1_element.tile_size", "16"                    },
-  { "game.panel.ce_score_1_element.element",   "custom_1"              },
+  { "game.panel.ce_score_1_element.element",   "empty_space"           },
   { "game.panel.ce_score_1_element.draw_masked","false"                        },
   { "game.panel.ce_score_1_element.draw_order",        "0"                     },
   { "game.panel.ce_score_2.x",                 "-1"                    },
@@ -5995,13 +6067,13 @@ struct ConfigInfo image_config[] =
   { "game.panel.ce_score_2.valign",            "top"                   },
   { "game.panel.ce_score_2.digits",            "-1"                    },
   { "game.panel.ce_score_2.font",              "font.text_2"           },
-  { "game.panel.ce_score_2.element",           "custom_1"              },
+  { "game.panel.ce_score_2.element",           "empty_space"           },
   { "game.panel.ce_score_2.draw_masked",       "true"                  },
   { "game.panel.ce_score_2.draw_order",                "0"                     },
   { "game.panel.ce_score_2_element.x",         "-1"                    },
   { "game.panel.ce_score_2_element.y",         "-1"                    },
   { "game.panel.ce_score_2_element.tile_size", "16"                    },
-  { "game.panel.ce_score_2_element.element",   "custom_1"              },
+  { "game.panel.ce_score_2_element.element",   "empty_space"           },
   { "game.panel.ce_score_2_element.draw_masked","false"                        },
   { "game.panel.ce_score_2_element.draw_order",        "0"                     },
   { "game.panel.ce_score_3.x",                 "-1"                    },
@@ -6010,13 +6082,13 @@ struct ConfigInfo image_config[] =
   { "game.panel.ce_score_3.valign",            "top"                   },
   { "game.panel.ce_score_3.digits",            "-1"                    },
   { "game.panel.ce_score_3.font",              "font.text_2"           },
-  { "game.panel.ce_score_3.element",           "custom_1"              },
+  { "game.panel.ce_score_3.element",           "empty_space"           },
   { "game.panel.ce_score_3.draw_masked",       "true"                  },
   { "game.panel.ce_score_3.draw_order",                "0"                     },
   { "game.panel.ce_score_3_element.x",         "-1"                    },
   { "game.panel.ce_score_3_element.y",         "-1"                    },
   { "game.panel.ce_score_3_element.tile_size", "16"                    },
-  { "game.panel.ce_score_3_element.element",   "custom_1"              },
+  { "game.panel.ce_score_3_element.element",   "empty_space"           },
   { "game.panel.ce_score_3_element.draw_masked","false"                        },
   { "game.panel.ce_score_3_element.draw_order",        "0"                     },
   { "game.panel.ce_score_4.x",                 "-1"                    },
@@ -6025,13 +6097,13 @@ struct ConfigInfo image_config[] =
   { "game.panel.ce_score_4.valign",            "top"                   },
   { "game.panel.ce_score_4.digits",            "-1"                    },
   { "game.panel.ce_score_4.font",              "font.text_2"           },
-  { "game.panel.ce_score_4.element",           "custom_1"              },
+  { "game.panel.ce_score_4.element",           "empty_space"           },
   { "game.panel.ce_score_4.draw_masked",       "true"                  },
   { "game.panel.ce_score_4.draw_order",                "0"                     },
   { "game.panel.ce_score_4_element.x",         "-1"                    },
   { "game.panel.ce_score_4_element.y",         "-1"                    },
   { "game.panel.ce_score_4_element.tile_size", "16"                    },
-  { "game.panel.ce_score_4_element.element",   "custom_1"              },
+  { "game.panel.ce_score_4_element.element",   "empty_space"           },
   { "game.panel.ce_score_4_element.draw_masked","false"                        },
   { "game.panel.ce_score_4_element.draw_order",        "0"                     },
   { "game.panel.ce_score_5.x",                 "-1"                    },
@@ -6040,13 +6112,13 @@ struct ConfigInfo image_config[] =
   { "game.panel.ce_score_5.valign",            "top"                   },
   { "game.panel.ce_score_5.digits",            "-1"                    },
   { "game.panel.ce_score_5.font",              "font.text_2"           },
-  { "game.panel.ce_score_5.element",           "custom_1"              },
+  { "game.panel.ce_score_5.element",           "empty_space"           },
   { "game.panel.ce_score_5.draw_masked",       "true"                  },
   { "game.panel.ce_score_5.draw_order",                "0"                     },
   { "game.panel.ce_score_5_element.x",         "-1"                    },
   { "game.panel.ce_score_5_element.y",         "-1"                    },
   { "game.panel.ce_score_5_element.tile_size", "16"                    },
-  { "game.panel.ce_score_5_element.element",   "custom_1"              },
+  { "game.panel.ce_score_5_element.element",   "empty_space"           },
   { "game.panel.ce_score_5_element.draw_masked","false"                        },
   { "game.panel.ce_score_5_element.draw_order",        "0"                     },
   { "game.panel.ce_score_6.x",                 "-1"                    },
@@ -6055,13 +6127,13 @@ struct ConfigInfo image_config[] =
   { "game.panel.ce_score_6.valign",            "top"                   },
   { "game.panel.ce_score_6.digits",            "-1"                    },
   { "game.panel.ce_score_6.font",              "font.text_2"           },
-  { "game.panel.ce_score_6.element",           "custom_1"              },
+  { "game.panel.ce_score_6.element",           "empty_space"           },
   { "game.panel.ce_score_6.draw_masked",       "true"                  },
   { "game.panel.ce_score_6.draw_order",                "0"                     },
   { "game.panel.ce_score_6_element.x",         "-1"                    },
   { "game.panel.ce_score_6_element.y",         "-1"                    },
   { "game.panel.ce_score_6_element.tile_size", "16"                    },
-  { "game.panel.ce_score_6_element.element",   "custom_1"              },
+  { "game.panel.ce_score_6_element.element",   "empty_space"           },
   { "game.panel.ce_score_6_element.draw_masked","false"                        },
   { "game.panel.ce_score_6_element.draw_order",        "0"                     },
   { "game.panel.ce_score_7.x",                 "-1"                    },
@@ -6070,13 +6142,13 @@ struct ConfigInfo image_config[] =
   { "game.panel.ce_score_7.valign",            "top"                   },
   { "game.panel.ce_score_7.digits",            "-1"                    },
   { "game.panel.ce_score_7.font",              "font.text_2"           },
-  { "game.panel.ce_score_7.element",           "custom_1"              },
+  { "game.panel.ce_score_7.element",           "empty_space"           },
   { "game.panel.ce_score_7.draw_masked",       "true"                  },
   { "game.panel.ce_score_7.draw_order",                "0"                     },
   { "game.panel.ce_score_7_element.x",         "-1"                    },
   { "game.panel.ce_score_7_element.y",         "-1"                    },
   { "game.panel.ce_score_7_element.tile_size", "16"                    },
-  { "game.panel.ce_score_7_element.element",   "custom_1"              },
+  { "game.panel.ce_score_7_element.element",   "empty_space"           },
   { "game.panel.ce_score_7_element.draw_masked","false"                        },
   { "game.panel.ce_score_7_element.draw_order",        "0"                     },
   { "game.panel.ce_score_8.x",                 "-1"                    },
@@ -6085,13 +6157,13 @@ struct ConfigInfo image_config[] =
   { "game.panel.ce_score_8.valign",            "top"                   },
   { "game.panel.ce_score_8.digits",            "-1"                    },
   { "game.panel.ce_score_8.font",              "font.text_2"           },
-  { "game.panel.ce_score_8.element",           "custom_1"              },
+  { "game.panel.ce_score_8.element",           "empty_space"           },
   { "game.panel.ce_score_8.draw_masked",       "true"                  },
   { "game.panel.ce_score_8.draw_order",                "0"                     },
   { "game.panel.ce_score_8_element.x",         "-1"                    },
   { "game.panel.ce_score_8_element.y",         "-1"                    },
   { "game.panel.ce_score_8_element.tile_size", "16"                    },
-  { "game.panel.ce_score_8_element.element",   "custom_1"              },
+  { "game.panel.ce_score_8_element.element",   "empty_space"           },
   { "game.panel.ce_score_8_element.draw_masked","false"                        },
   { "game.panel.ce_score_8_element.draw_order",        "0"                     },
 
index 799331dc4dd8efe1b6c7aa8751dba6ffa0591b61..3cf2fae60b1cd9602aa5d4938155814415aa47ea 100644 (file)
@@ -3648,6 +3648,42 @@ struct TokenIntPtrInfo image_config_vars[] =
     "game.panel.element_1.draw_order",
     &game.panel.element[0].sort_priority
   },
+  {
+    "game.panel.element_1_count.x",
+    &game.panel.element_count[0].x
+  },
+  {
+    "game.panel.element_1_count.y",
+    &game.panel.element_count[0].y
+  },
+  {
+    "game.panel.element_1_count.align",
+    &game.panel.element_count[0].align
+  },
+  {
+    "game.panel.element_1_count.valign",
+    &game.panel.element_count[0].valign
+  },
+  {
+    "game.panel.element_1_count.digits",
+    &game.panel.element_count[0].size
+  },
+  {
+    "game.panel.element_1_count.font",
+    &game.panel.element_count[0].font
+  },
+  {
+    "game.panel.element_1_count.element",
+    &game.panel.element_count[0].id
+  },
+  {
+    "game.panel.element_1_count.draw_masked",
+    &game.panel.element_count[0].draw_masked
+  },
+  {
+    "game.panel.element_1_count.draw_order",
+    &game.panel.element_count[0].sort_priority
+  },
   {
     "game.panel.element_2.x",
     &game.panel.element[1].x
@@ -3672,6 +3708,42 @@ struct TokenIntPtrInfo image_config_vars[] =
     "game.panel.element_2.draw_order",
     &game.panel.element[1].sort_priority
   },
+  {
+    "game.panel.element_2_count.x",
+    &game.panel.element_count[1].x
+  },
+  {
+    "game.panel.element_2_count.y",
+    &game.panel.element_count[1].y
+  },
+  {
+    "game.panel.element_2_count.align",
+    &game.panel.element_count[1].align
+  },
+  {
+    "game.panel.element_2_count.valign",
+    &game.panel.element_count[1].valign
+  },
+  {
+    "game.panel.element_2_count.digits",
+    &game.panel.element_count[1].size
+  },
+  {
+    "game.panel.element_2_count.font",
+    &game.panel.element_count[1].font
+  },
+  {
+    "game.panel.element_2_count.element",
+    &game.panel.element_count[1].id
+  },
+  {
+    "game.panel.element_2_count.draw_masked",
+    &game.panel.element_count[1].draw_masked
+  },
+  {
+    "game.panel.element_2_count.draw_order",
+    &game.panel.element_count[1].sort_priority
+  },
   {
     "game.panel.element_3.x",
     &game.panel.element[2].x
@@ -3696,6 +3768,42 @@ struct TokenIntPtrInfo image_config_vars[] =
     "game.panel.element_3.draw_order",
     &game.panel.element[2].sort_priority
   },
+  {
+    "game.panel.element_3_count.x",
+    &game.panel.element_count[2].x
+  },
+  {
+    "game.panel.element_3_count.y",
+    &game.panel.element_count[2].y
+  },
+  {
+    "game.panel.element_3_count.align",
+    &game.panel.element_count[2].align
+  },
+  {
+    "game.panel.element_3_count.valign",
+    &game.panel.element_count[2].valign
+  },
+  {
+    "game.panel.element_3_count.digits",
+    &game.panel.element_count[2].size
+  },
+  {
+    "game.panel.element_3_count.font",
+    &game.panel.element_count[2].font
+  },
+  {
+    "game.panel.element_3_count.element",
+    &game.panel.element_count[2].id
+  },
+  {
+    "game.panel.element_3_count.draw_masked",
+    &game.panel.element_count[2].draw_masked
+  },
+  {
+    "game.panel.element_3_count.draw_order",
+    &game.panel.element_count[2].sort_priority
+  },
   {
     "game.panel.element_4.x",
     &game.panel.element[3].x
@@ -3720,6 +3828,42 @@ struct TokenIntPtrInfo image_config_vars[] =
     "game.panel.element_4.draw_order",
     &game.panel.element[3].sort_priority
   },
+  {
+    "game.panel.element_4_count.x",
+    &game.panel.element_count[3].x
+  },
+  {
+    "game.panel.element_4_count.y",
+    &game.panel.element_count[3].y
+  },
+  {
+    "game.panel.element_4_count.align",
+    &game.panel.element_count[3].align
+  },
+  {
+    "game.panel.element_4_count.valign",
+    &game.panel.element_count[3].valign
+  },
+  {
+    "game.panel.element_4_count.digits",
+    &game.panel.element_count[3].size
+  },
+  {
+    "game.panel.element_4_count.font",
+    &game.panel.element_count[3].font
+  },
+  {
+    "game.panel.element_4_count.element",
+    &game.panel.element_count[3].id
+  },
+  {
+    "game.panel.element_4_count.draw_masked",
+    &game.panel.element_count[3].draw_masked
+  },
+  {
+    "game.panel.element_4_count.draw_order",
+    &game.panel.element_count[3].sort_priority
+  },
   {
     "game.panel.element_5.x",
     &game.panel.element[4].x
@@ -3744,6 +3888,42 @@ struct TokenIntPtrInfo image_config_vars[] =
     "game.panel.element_5.draw_order",
     &game.panel.element[4].sort_priority
   },
+  {
+    "game.panel.element_5_count.x",
+    &game.panel.element_count[4].x
+  },
+  {
+    "game.panel.element_5_count.y",
+    &game.panel.element_count[4].y
+  },
+  {
+    "game.panel.element_5_count.align",
+    &game.panel.element_count[4].align
+  },
+  {
+    "game.panel.element_5_count.valign",
+    &game.panel.element_count[4].valign
+  },
+  {
+    "game.panel.element_5_count.digits",
+    &game.panel.element_count[4].size
+  },
+  {
+    "game.panel.element_5_count.font",
+    &game.panel.element_count[4].font
+  },
+  {
+    "game.panel.element_5_count.element",
+    &game.panel.element_count[4].id
+  },
+  {
+    "game.panel.element_5_count.draw_masked",
+    &game.panel.element_count[4].draw_masked
+  },
+  {
+    "game.panel.element_5_count.draw_order",
+    &game.panel.element_count[4].sort_priority
+  },
   {
     "game.panel.element_6.x",
     &game.panel.element[5].x
@@ -3768,6 +3948,42 @@ struct TokenIntPtrInfo image_config_vars[] =
     "game.panel.element_6.draw_order",
     &game.panel.element[5].sort_priority
   },
+  {
+    "game.panel.element_6_count.x",
+    &game.panel.element_count[5].x
+  },
+  {
+    "game.panel.element_6_count.y",
+    &game.panel.element_count[5].y
+  },
+  {
+    "game.panel.element_6_count.align",
+    &game.panel.element_count[5].align
+  },
+  {
+    "game.panel.element_6_count.valign",
+    &game.panel.element_count[5].valign
+  },
+  {
+    "game.panel.element_6_count.digits",
+    &game.panel.element_count[5].size
+  },
+  {
+    "game.panel.element_6_count.font",
+    &game.panel.element_count[5].font
+  },
+  {
+    "game.panel.element_6_count.element",
+    &game.panel.element_count[5].id
+  },
+  {
+    "game.panel.element_6_count.draw_masked",
+    &game.panel.element_count[5].draw_masked
+  },
+  {
+    "game.panel.element_6_count.draw_order",
+    &game.panel.element_count[5].sort_priority
+  },
   {
     "game.panel.element_7.x",
     &game.panel.element[6].x
@@ -3792,6 +4008,42 @@ struct TokenIntPtrInfo image_config_vars[] =
     "game.panel.element_7.draw_order",
     &game.panel.element[6].sort_priority
   },
+  {
+    "game.panel.element_7_count.x",
+    &game.panel.element_count[6].x
+  },
+  {
+    "game.panel.element_7_count.y",
+    &game.panel.element_count[6].y
+  },
+  {
+    "game.panel.element_7_count.align",
+    &game.panel.element_count[6].align
+  },
+  {
+    "game.panel.element_7_count.valign",
+    &game.panel.element_count[6].valign
+  },
+  {
+    "game.panel.element_7_count.digits",
+    &game.panel.element_count[6].size
+  },
+  {
+    "game.panel.element_7_count.font",
+    &game.panel.element_count[6].font
+  },
+  {
+    "game.panel.element_7_count.element",
+    &game.panel.element_count[6].id
+  },
+  {
+    "game.panel.element_7_count.draw_masked",
+    &game.panel.element_count[6].draw_masked
+  },
+  {
+    "game.panel.element_7_count.draw_order",
+    &game.panel.element_count[6].sort_priority
+  },
   {
     "game.panel.element_8.x",
     &game.panel.element[7].x
@@ -3816,6 +4068,42 @@ struct TokenIntPtrInfo image_config_vars[] =
     "game.panel.element_8.draw_order",
     &game.panel.element[7].sort_priority
   },
+  {
+    "game.panel.element_8_count.x",
+    &game.panel.element_count[7].x
+  },
+  {
+    "game.panel.element_8_count.y",
+    &game.panel.element_count[7].y
+  },
+  {
+    "game.panel.element_8_count.align",
+    &game.panel.element_count[7].align
+  },
+  {
+    "game.panel.element_8_count.valign",
+    &game.panel.element_count[7].valign
+  },
+  {
+    "game.panel.element_8_count.digits",
+    &game.panel.element_count[7].size
+  },
+  {
+    "game.panel.element_8_count.font",
+    &game.panel.element_count[7].font
+  },
+  {
+    "game.panel.element_8_count.element",
+    &game.panel.element_count[7].id
+  },
+  {
+    "game.panel.element_8_count.draw_masked",
+    &game.panel.element_count[7].draw_masked
+  },
+  {
+    "game.panel.element_8_count.draw_order",
+    &game.panel.element_count[7].sort_priority
+  },
   {
     "game.panel.ce_score_1.x",
     &game.panel.ce_score[0].x
index 40671e4fc0996c801772b90dd4ff1270d0f387fe..a633a1bd13fbfc9c3e928df3d1e24c12ccac84c1 100644 (file)
@@ -1 +1 @@
-#define COMPILE_DATE_STRING "2007-04-10 00:36"
+#define COMPILE_DATE_STRING "2007-04-13 22:02"
index d24c62f6b324b0d815eebff9581e847b997ac451..f600e0462613cf1b878924af1dfccfc25802e06e 100644 (file)
 #define GAME_PANEL_ELEMENT_6                   74
 #define GAME_PANEL_ELEMENT_7                   75
 #define GAME_PANEL_ELEMENT_8                   76
-#define GAME_PANEL_CE_SCORE_1                  77
-#define GAME_PANEL_CE_SCORE_2                  78
-#define GAME_PANEL_CE_SCORE_3                  79
-#define GAME_PANEL_CE_SCORE_4                  80
-#define GAME_PANEL_CE_SCORE_5                  81
-#define GAME_PANEL_CE_SCORE_6                  82
-#define GAME_PANEL_CE_SCORE_7                  83
-#define GAME_PANEL_CE_SCORE_8                  84
-#define GAME_PANEL_CE_SCORE_1_ELEMENT          85
-#define GAME_PANEL_CE_SCORE_2_ELEMENT          86
-#define GAME_PANEL_CE_SCORE_3_ELEMENT          87
-#define GAME_PANEL_CE_SCORE_4_ELEMENT          88
-#define GAME_PANEL_CE_SCORE_5_ELEMENT          89
-#define GAME_PANEL_CE_SCORE_6_ELEMENT          90
-#define GAME_PANEL_CE_SCORE_7_ELEMENT          91
-#define GAME_PANEL_CE_SCORE_8_ELEMENT          92
-#define GAME_PANEL_PLAYER_NAME                 93
-#define GAME_PANEL_LEVEL_NAME                  94
-#define GAME_PANEL_LEVEL_AUTHOR                        95
-
-#define NUM_GAME_PANEL_CONTROLS                        96
+#define GAME_PANEL_ELEMENT_COUNT_1             77
+#define GAME_PANEL_ELEMENT_COUNT_2             78
+#define GAME_PANEL_ELEMENT_COUNT_3             79
+#define GAME_PANEL_ELEMENT_COUNT_4             80
+#define GAME_PANEL_ELEMENT_COUNT_5             81
+#define GAME_PANEL_ELEMENT_COUNT_6             82
+#define GAME_PANEL_ELEMENT_COUNT_7             83
+#define GAME_PANEL_ELEMENT_COUNT_8             84
+#define GAME_PANEL_CE_SCORE_1                  85
+#define GAME_PANEL_CE_SCORE_2                  86
+#define GAME_PANEL_CE_SCORE_3                  87
+#define GAME_PANEL_CE_SCORE_4                  88
+#define GAME_PANEL_CE_SCORE_5                  89
+#define GAME_PANEL_CE_SCORE_6                  90
+#define GAME_PANEL_CE_SCORE_7                  91
+#define GAME_PANEL_CE_SCORE_8                  92
+#define GAME_PANEL_CE_SCORE_1_ELEMENT          93
+#define GAME_PANEL_CE_SCORE_2_ELEMENT          94
+#define GAME_PANEL_CE_SCORE_3_ELEMENT          95
+#define GAME_PANEL_CE_SCORE_4_ELEMENT          96
+#define GAME_PANEL_CE_SCORE_5_ELEMENT          97
+#define GAME_PANEL_CE_SCORE_6_ELEMENT          98
+#define GAME_PANEL_CE_SCORE_7_ELEMENT          99
+#define GAME_PANEL_CE_SCORE_8_ELEMENT          100
+#define GAME_PANEL_PLAYER_NAME                 101
+#define GAME_PANEL_LEVEL_NAME                  102
+#define GAME_PANEL_LEVEL_AUTHOR                        103
+
+#define NUM_GAME_PANEL_CONTROLS                        104
 
 struct GamePanelOrderInfo
 {
@@ -638,6 +646,46 @@ static struct GamePanelControlInfo game_panel_controls[] =
     &game.panel.element[7],
     TYPE_ELEMENT,
   },
+  {
+    GAME_PANEL_ELEMENT_COUNT_1,
+    &game.panel.element_count[0],
+    TYPE_INTEGER,
+  },
+  {
+    GAME_PANEL_ELEMENT_COUNT_2,
+    &game.panel.element_count[1],
+    TYPE_INTEGER,
+  },
+  {
+    GAME_PANEL_ELEMENT_COUNT_3,
+    &game.panel.element_count[2],
+    TYPE_INTEGER,
+  },
+  {
+    GAME_PANEL_ELEMENT_COUNT_4,
+    &game.panel.element_count[3],
+    TYPE_INTEGER,
+  },
+  {
+    GAME_PANEL_ELEMENT_COUNT_5,
+    &game.panel.element_count[4],
+    TYPE_INTEGER,
+  },
+  {
+    GAME_PANEL_ELEMENT_COUNT_6,
+    &game.panel.element_count[5],
+    TYPE_INTEGER,
+  },
+  {
+    GAME_PANEL_ELEMENT_COUNT_7,
+    &game.panel.element_count[6],
+    TYPE_INTEGER,
+  },
+  {
+    GAME_PANEL_ELEMENT_COUNT_8,
+    &game.panel.element_count[7],
+    TYPE_INTEGER,
+  },
   {
     GAME_PANEL_CE_SCORE_1,
     &game.panel.ce_score[0],
@@ -2010,6 +2058,25 @@ void InitGameControlValues()
        sizeof(struct GamePanelOrderInfo), compareGamePanelOrderInfo);
 }
 
+void UpdatePlayfieldElementCount()
+{
+  int i, j, x, y;
+
+  for (i = 0; i < MAX_NUM_ELEMENTS; i++)
+    element_info[i].element_count = 0;
+
+  SCAN_PLAYFIELD(x, y)
+  {
+    element_info[Feld[x][y]].element_count++;
+  }
+
+  for (i = 0; i < NUM_GROUP_ELEMENTS; i++)
+    for (j = 0; j < MAX_NUM_ELEMENTS; j++)
+      if (IS_IN_GROUP(j, i))
+       element_info[EL_GROUP_START + i].element_count +=
+         element_info[j].element_count;
+}
+
 void UpdateGameControlValues()
 {
   int i, k;
@@ -2032,6 +2099,10 @@ void UpdateGameControlValues()
                     local_player->sokobanfields_still_needed > 0 ||
                     local_player->lights_still_needed > 0);
 
+  UpdatePlayfieldElementCount();
+
+  /* update game panel control values */
+
   game_panel_controls[GAME_PANEL_LEVEL_NUMBER].value = level_nr;
   game_panel_controls[GAME_PANEL_GEMS].value = gems;
 
@@ -2214,6 +2285,12 @@ void UpdateGameControlValues()
       (IS_DRAWABLE_ELEMENT(game.panel.element[i].id) ?
        game.panel.element[i].id : EL_UNDEFINED);
 
+  for (i = 0; i < NUM_PANEL_ELEMENTS; i++)
+    game_panel_controls[GAME_PANEL_ELEMENT_COUNT_1 + i].value =
+      (IS_VALID_ELEMENT(game.panel.element_count[i].id) ?
+       element_info[game.panel.element_count[i].id].element_count :
+       EL_UNDEFINED);
+
   for (i = 0; i < NUM_PANEL_CE_SCORE; i++)
     game_panel_controls[GAME_PANEL_CE_SCORE_1 + i].value =
       (IS_CUSTOM_ELEMENT(game.panel.ce_score[i].id) ?
@@ -2229,6 +2306,8 @@ void UpdateGameControlValues()
   game_panel_controls[GAME_PANEL_LEVEL_NAME].value = 0;
   game_panel_controls[GAME_PANEL_LEVEL_AUTHOR].value = 0;
 
+  /* update game panel control frames */
+
   for (i = 0; game_panel_controls[i].nr != -1; i++)
   {
     struct GamePanelControlInfo *gpc = &game_panel_controls[i];
index 5b2b46a95d8b6a0eaf901672efff41d0dada1cc0..241889b08291aad0e16a7d8802c4363ba9376f32 100644 (file)
@@ -75,6 +75,7 @@ struct GamePanelInfo
   struct TextPosInfo magic_wall_time;
   struct TextPosInfo gravity_state;
   struct TextPosInfo element[NUM_PANEL_ELEMENTS];
+  struct TextPosInfo element_count[NUM_PANEL_ELEMENTS];
   struct TextPosInfo ce_score[NUM_PANEL_CE_SCORE];
   struct TextPosInfo ce_score_element[NUM_PANEL_CE_SCORE];
   struct TextPosInfo player_name;
index 938eb26ad53930649a7686496e91fb14a8c90cea..2f323f279a3f05d55b2581c18a276339dfb4c0c9 100644 (file)
@@ -2474,6 +2474,9 @@ struct ElementInfo
 
   int collect_score;           /* runtime score value for collecting */
 
+  /* count of this element on playfield, calculated after each frame */
+  int element_count;
+
   /* ---------- internal values used in level editor ---------- */
 
   int access_type;             /* walkable or passable */