GADGET_ID_BD_VOODOO_HURT_KILLS_PLAYER,
GADGET_ID_BD_VOODOO_DIES_BY_ROCK,
GADGET_ID_BD_VOODOO_VANISH_BY_EXPLOSION,
+ GADGET_ID_BD_SLIME_IS_PREDICTABLE,
GADGET_ID_ENVELOPE_AUTOWRAP,
GADGET_ID_ENVELOPE_CENTERED,
GADGET_ID_MM_LASER_RED,
ED_CHECKBUTTON_ID_BD_VOODOO_HURT_KILLS_PLAYER,
ED_CHECKBUTTON_ID_BD_VOODOO_DIES_BY_ROCK,
ED_CHECKBUTTON_ID_BD_VOODOO_VANISH_BY_EXPLOSION,
+ ED_CHECKBUTTON_ID_BD_SLIME_IS_PREDICTABLE,
ED_CHECKBUTTON_ID_ENVELOPE_AUTOWRAP,
ED_CHECKBUTTON_ID_ENVELOPE_CENTERED,
ED_CHECKBUTTON_ID_MM_LASER_RED,
NULL, NULL,
"disappears in explosions", "can be destroyed by explosions"
},
+ {
+ ED_CHECKBUTTON_ID_BD_SLIME_IS_PREDICTABLE,
+ ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(0),
+ GADGET_ID_BD_SLIME_IS_PREDICTABLE, GADGET_ID_NONE,
+ &level.bd_slime_is_predictable,
+ NULL, NULL,
+ "slime is predictable", "use predictable random numbers"
+ },
{
ED_CHECKBUTTON_ID_ENVELOPE_AUTOWRAP,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
#define TEXT_GAME_OF_LIFE_4 "Max neighbours to create"
#define TEXT_TIME_BONUS "Extra time to solve level"
#define TEXT_TIME_PENALTY "Time penalty if destroyed"
+#define TEXT_PERMEABILITY_RATE "slime permeability rate"
+#define TEXT_PERMEABILITY_BITS "slime permeability bits"
+#define TEXT_RANDOM_SEED "slime random number seed"
static struct
{
-100, 100 },
{ EL_BD_VOODOO_DOLL, &level.bd_voodoo_penalty_time, TEXT_TIME_PENALTY,
0, 100 },
+ { EL_BD_SLIME, &level.bd_slime_permeability_rate, TEXT_PERMEABILITY_RATE,
+ 0, 100 },
+ { EL_BD_SLIME, &level.bd_slime_permeability_bits_c64, TEXT_PERMEABILITY_BITS,
+ 0, 255 },
+ { EL_BD_SLIME, &level.bd_slime_random_seed_c64, TEXT_RANDOM_SEED,
+ -1, 65535 },
{ EL_EXTRA_TIME, &level.extra_time, TEXT_TIME_BONUS },
{ EL_TIME_ORB_FULL, &level.time_orb_time, TEXT_TIME_BONUS },
{ EL_GAME_OF_LIFE, &level.game_of_life[0], TEXT_GAME_OF_LIFE_1,0,8 },
(COULD_MOVE_INTO_ACID(properties_element) ? 1 : 0) +
(MAYBE_DONT_COLLIDE_WITH(properties_element) ? 1 : 0) +
(properties_element == EL_BD_VOODOO_DOLL ? 4 : 0) +
+ (properties_element == EL_BD_SLIME ? 1 : 0) +
(properties_element == EL_EMC_MAGIC_BALL ? 2 : 0) +
num_element_counters);
MapCheckbuttonGadget(ED_CHECKBUTTON_ID_BD_VOODOO_VANISH_BY_EXPLOSION);
}
+ if (properties_element == EL_BD_SLIME)
+ {
+ MapCheckbuttonGadget(ED_CHECKBUTTON_ID_BD_SLIME_IS_PREDICTABLE);
+ }
+
if (properties_element == EL_BD_MAGIC_WALL)
{
MapCheckbuttonGadget(ED_CHECKBUTTON_ID_BD_MAGIC_WALL_WAIT_HATCHING);
&li.bd_voodoo_penalty_time, 30
},
+ {
+ EL_BD_SLIME, -1,
+ TYPE_BOOLEAN, CONF_VALUE_8_BIT(1),
+ &li.bd_slime_is_predictable, TRUE
+ },
+ {
+ EL_BD_SLIME, -1,
+ TYPE_INTEGER, CONF_VALUE_8_BIT(2),
+ &li.bd_slime_permeability_rate, 100
+ },
+ {
+ EL_BD_SLIME, -1,
+ TYPE_INTEGER, CONF_VALUE_8_BIT(3),
+ &li.bd_slime_permeability_bits_c64, 0
+ },
+ {
+ EL_BD_SLIME, -1,
+ TYPE_INTEGER, CONF_VALUE_32_BIT(1),
+ &li.bd_slime_random_seed_c64, -1
+ },
// (the following values are related to various game elements)
cave->amoeba_2_explosion_effect = map_element_RND_to_BD(level->bd_amoeba_2_content_exploding);
cave->amoeba_2_looks_like = map_element_RND_to_BD(level->bd_amoeba_2_content_looks_like);
+ cave->slime_predictable = level->bd_slime_is_predictable;
+ cave->level_slime_permeability[0] = level->bd_slime_permeability_rate * 10000;
+ cave->level_slime_permeability_c64[0] = level->bd_slime_permeability_bits_c64;
+ cave->level_slime_seed_c64[0] = level->bd_slime_random_seed_c64;
+
// level name
strncpy(cave->name, level->name, sizeof(GdString));
cave->name[sizeof(GdString) - 1] = '\0';
level->bd_amoeba_2_content_exploding = map_element_BD_to_RND(cave->amoeba_2_explosion_effect);
level->bd_amoeba_2_content_looks_like = map_element_BD_to_RND(cave->amoeba_2_looks_like);
+ level->bd_slime_is_predictable = cave->slime_predictable;
+ level->bd_slime_permeability_rate = cave->level_slime_permeability[0] / 10000;
+ level->bd_slime_permeability_bits_c64 = cave->level_slime_permeability_c64[0];
+ level->bd_slime_random_seed_c64 = cave->level_slime_seed_c64[0];
+
// level name
char *cave_name = getStringPrint("%s / %d", cave->name, bd_level_nr + 1);