TYPE_SWITCH3,
&setup.bd_up_down_graphics, "bd_up_down_graphics"
},
+ {
+ TYPE_SWITCH3,
+ &setup.bd_skip_falling_sounds, "bd_skip_falling_sounds"
+ },
{
TYPE_INTEGER,
&setup.bd_palette_c64, "bd_palette_c64"
si->bd_smooth_movements = AUTO;
si->bd_pushing_graphics = TRUE;
si->bd_up_down_graphics = TRUE;
+ si->bd_skip_falling_sounds = AUTO;
si->bd_palette_c64 = GD_DEFAULT_PALETTE_C64;
si->bd_palette_c64dtv = GD_DEFAULT_PALETTE_C64DTV;
si->bd_palette_atari = GD_DEFAULT_PALETTE_ATARI;
}
}
+// returns true if the element can fall
+static inline boolean el_can_fall(const int element)
+{
+ return (gd_elements[element & O_MASK].properties & P_CAN_FALL) != 0;
+}
+
// play diamond or stone sound of given element.
static void play_sound_of_element(GdCave *cave, GdElement element, int x, int y)
{
+ // check if sound should be skipped for falling elements (and only be played on impact)
+ if (el_can_fall(element) && skip_bd_falling_sounds())
+ return;
+
// stone and diamond fall sounds.
switch (element)
{
boolean use_bd_smooth_movements(void);
boolean use_bd_pushing_graphics(void);
boolean use_bd_up_down_graphics(void);
+boolean skip_bd_falling_sounds(void);
Bitmap **GetTitleScreenBitmaps_BD(void);
void CoverScreen_BD(void);
(setup.bd_up_down_graphics == AUTO && !use_native_bd_graphics_engine()));
}
+// check if skipping falling sounds selected in setup menu
+boolean skip_bd_falling_sounds(void)
+{
+ return ((setup.bd_skip_falling_sounds == TRUE) ||
+ (setup.bd_skip_falling_sounds == AUTO && !game.use_native_bd_sound_engine));
+}
+
Bitmap **GetTitleScreenBitmaps_BD(void)
{
Bitmap **title_screen_bitmaps = gd_get_title_screen_bitmaps();
int bd_smooth_movements; // not boolean -- can also be "AUTO"
int bd_pushing_graphics; // not boolean -- can also be "AUTO"
int bd_up_down_graphics; // not boolean -- can also be "AUTO"
+ int bd_skip_falling_sounds; // not boolean -- can also be "AUTO"
int bd_palette_c64;
int bd_palette_c64dtv;
int bd_palette_atari;
{ TYPE_YES_NO_AUTO, &setup.bd_smooth_movements, "Smooth Element Movement:" },
{ TYPE_YES_NO_AUTO, &setup.bd_pushing_graphics, "Use Player Pushing Graphics:" },
{ TYPE_YES_NO_AUTO, &setup.bd_up_down_graphics, "Use Player Up/Down Graphics:" },
+ { TYPE_YES_NO_AUTO, &setup.bd_skip_falling_sounds, "Mute Double Falling Sounds:" },
{ TYPE_ENTER_LIST, &execSetupChoosePaletteC64, "Color Palette (C64):" },
{ TYPE_STRING, &bd_palette_c64_text, "" },
{ TYPE_ENTER_LIST, &execSetupChoosePaletteC64DTV, "Color Palette (C64DTV):" },