rnd-20040621-1-src
[rocksndiamonds.git] / src / conf_snd.c
1 /***********************************************************
2 * Rocks'n'Diamonds -- McDuffin Strikes Back!               *
3 *----------------------------------------------------------*
4 * (c) 1995-2002 Artsoft Entertainment                      *
5 *               Holger Schemel                             *
6 *               Detmolder Strasse 189                      *
7 *               33604 Bielefeld                            *
8 *               Germany                                    *
9 *               e-mail: info@artsoft.org                   *
10 *----------------------------------------------------------*
11 * conf_snd.c                                               *
12 ***********************************************************/
13
14 #include "libgame/libgame.h"
15 #include "main.h"
16
17
18 /* List values that are not defined in the configuration file are set to
19    reliable default values. If that value is SND_ARG_UNDEFINED, it will
20    be dynamically determined, using some of the other list values. */
21
22 struct ConfigTypeInfo sound_config_suffix[] =
23 {
24   { ".mode_loop",                       ARG_UNDEFINED,  TYPE_BOOLEAN    },
25
26   { NULL,                               NULL,           0               }
27 };
28
29 struct ConfigInfo sound_config[] =
30 {
31   /* some default sounds */
32   { "[default].digging",                "schlurf.wav"                   },
33   { "[default].collecting",             "pong.wav"                      },
34   { "[default].snapping",               "pong.wav"                      },
35   { "[default].pushing",                "pusch.wav"                     },
36   { "[default].impact",                 "klopf.wav"                     },
37   { "[default].walking",                "empty.wav"                     },
38   { "[default].passing",                "gate.wav"                      },
39   { "[default].dying",                  "autsch.wav"                    },
40   { "[default].exploding",              "roaaar.wav"                    },
41   { "[sp_default].exploding",           "booom.wav"                     },
42
43   /* sounds for Boulder Dash style elements and actions */
44   { "bd_diamond.collecting",            "pong.wav"                      },
45   { "bd_diamond.impact",                "pling.wav"                     },
46   { "bd_rock.pushing",                  "pusch.wav"                     },
47   { "bd_rock.impact",                   "klopf.wav"                     },
48   { "bd_magic_wall.activating",         "quirk.wav"                     },
49   { "bd_magic_wall.active",             "miep.wav"                      },
50   { "bd_magic_wall.filling",            "quirk.wav"                     },
51   { "bd_amoeba.waiting",                UNDEFINED_FILENAME              },
52   { "bd_amoeba.growing",                "amoebe.wav"                    },
53   { "bd_amoeba.turning_to_gem",         "pling.wav"                     },
54   { "bd_amoeba.turning_to_rock",        "klopf.wav"                     },
55   { "bd_butterfly.moving",              "klapper.wav"                   },
56   { "bd_butterfly.waiting",             "klapper.wav"                   },
57   { "bd_firefly.moving",                "roehr.wav"                     },
58   { "bd_firefly.waiting",               "roehr.wav"                     },
59
60   /* sounds for Supaplex style elements and actions */
61   { "sp_base.digging",                  "base.wav"                      },
62   { "sp_buggy_base.digging",            "base.wav"                      },
63   { "sp_buggy_base.active",             "bug.wav"                       },
64   { "sp_infotron.collecting",           "infotron.wav"                  },
65   { "sp_infotron.impact",               "pling.wav"                     },
66   { "sp_zonk.pushing",                  "zonkpush.wav"                  },
67   { "sp_zonk.impact",                   "zonkdown.wav"                  },
68   { "sp_disk_red.collecting",           "infotron.wav"                  },
69   { "sp_disk_orange.pushing",           "zonkpush.wav"                  },
70   { "sp_disk_yellow.pushing",           "pusch.wav"                     },
71   { "[sp_port].passing",                "gate.wav"                      },
72   { "[sp_exit].passing",                "exit.wav"                      },
73   { "[sp_exit].opening",                UNDEFINED_FILENAME              },
74   { "[sp_exit].closing",                UNDEFINED_FILENAME              },
75   { "sp_sniksnak.moving",               UNDEFINED_FILENAME              },
76   { "sp_sniksnak.waiting",              UNDEFINED_FILENAME              },
77   { "sp_electron.moving",               UNDEFINED_FILENAME              },
78   { "sp_electron.waiting",              UNDEFINED_FILENAME              },
79   { "sp_terminal.activating",           UNDEFINED_FILENAME              },
80   { "sp_terminal.active",               UNDEFINED_FILENAME              },
81
82   /* sounds for Sokoban style elements and actions */
83   { "[sokoban].pushing",                "pusch.wav"                     },
84   { "[sokoban].filling",                "deng.wav"                      },
85   { "[sokoban].emptying",               UNDEFINED_FILENAME              },
86
87   /* sounds for Emerald Mine style elements and actions */
88   { "[player].moving",                  "empty.wav"                     },
89   { "[player].moving.mode_loop",        "false"                         },
90   { "sand.digging",                     "schlurf.wav"                   },
91   { "[emerald].collecting",             "pong.wav"                      },
92   { "[emerald].impact",                 "pling.wav"                     },
93   { "diamond.collecting",               "pong.wav"                      },
94   { "diamond.impact",                   "pling.wav"                     },
95   { "diamond.breaking",                 "quirk.wav"                     },
96   { "rock.pushing",                     "pusch.wav"                     },
97   { "rock.impact",                      "klopf.wav"                     },
98   { "bomb.pushing",                     "pusch.wav"                     },
99   { "nut.pushing",                      "knurk.wav"                     },
100   { "nut.breaking",                     "knack.wav"                     },
101   { "nut.impact",                       "klumpf.wav"                    },
102   { "[dynamite].collecting",            "pong.wav"                      },
103   { "[dynamite].dropping",              "deng.wav"                      },
104   { "[dynamite].active",                "zisch.wav"                     },
105   { "[key].collecting",                 "pong.wav"                      },
106   { "[gate].passing",                   "gate.wav"                      },
107   { "bug.moving",                       "klapper.wav"                   },
108   { "bug.waiting",                      "klapper.wav"                   },
109   { "spaceship.moving",                 "roehr.wav"                     },
110   { "spaceship.waiting",                "roehr.wav"                     },
111   { "yamyam.moving",                    UNDEFINED_FILENAME              },
112   { "yamyam.waiting",                   "njam.wav"                      },
113   { "yamyam.digging",                   UNDEFINED_FILENAME              },
114   { "robot.moving",                     "schlurf.wav"                   },
115   { "robot.moving.mode_loop",           "false"                         },
116   { "robot.waiting",                    UNDEFINED_FILENAME              },
117   { "robot_wheel.activating",           "deng.wav"                      },
118   { "robot_wheel.active",               "miep.wav"                      },
119   { "magic_wall.activating",            "quirk.wav"                     },
120   { "magic_wall.active",                "miep.wav"                      },
121   { "magic_wall.filling",               "quirk.wav"                     },
122   { "[amoeba].waiting",                 UNDEFINED_FILENAME              },
123   { "[amoeba].growing",                 "amoebe.wav"                    },
124   { "[amoeba].dropping",                UNDEFINED_FILENAME              },
125   { "acid.splashing",                   "blurb.wav"                     },
126   { "[quicksand].filling",              UNDEFINED_FILENAME              },
127   { "[quicksand].emptying",             UNDEFINED_FILENAME              },
128   { "[exit].opening",                   "oeffnen.wav"                   },
129   { "[exit].closing",                   "oeffnen.wav"                   },
130   { "[exit].passing",                   "buing.wav"                     },
131   { "penguin.passing",                  "buing.wav"                     },
132
133   /* sounds for Emerald Mine Club style elements and actions */
134   { "balloon.moving",                   UNDEFINED_FILENAME              },
135   { "balloon.waiting",                  UNDEFINED_FILENAME              },
136   { "balloon.pushing",                  "schlurf.wav"                   },
137   { "[balloon_switch].activating",      UNDEFINED_FILENAME              },
138   { "spring.moving",                    UNDEFINED_FILENAME              },
139   { "spring.pushing",                   "pusch.wav"                     },
140   { "spring.impact",                    "klopf.wav"                     },
141   { "[wall].growing",                   UNDEFINED_FILENAME              },
142
143   /* sounds for Diamond Caves style elements and actions */
144   { "pearl.collecting",                 "pong.wav"                      },
145   { "pearl.breaking",                   "knack.wav"                     },
146   { "pearl.impact",                     "pling.wav"                     },
147   { "crystal.collecting",               "pong.wav"                      },
148   { "crystal.impact",                   "pling.wav"                     },
149   { "[envelope].collecting",            "pong.wav"                      },
150   { "[envelope].opening",               UNDEFINED_FILENAME              },
151   { "[envelope].closing",               UNDEFINED_FILENAME              },
152   { "invisible_sand.digging",           "schlurf.wav"                   },
153   { "shield_normal.collecting",         "pong.wav"                      },
154   { "shield_normal.active",             UNDEFINED_FILENAME              },
155   { "shield_deadly.collecting",         "pong.wav"                      },
156   { "shield_deadly.active",             UNDEFINED_FILENAME              },
157   { "extra_time.collecting",            "gong.wav"                      },
158   { "mole.moving",                      UNDEFINED_FILENAME              },
159   { "mole.waiting",                     UNDEFINED_FILENAME              },
160   { "mole.digging",                     "blurb.wav"                     },
161   { "[switchgate_switch].activating",   UNDEFINED_FILENAME              },
162   { "[switchgate].opening",             "oeffnen.wav"                   },
163   { "[switchgate].closing",             "oeffnen.wav"                   },
164   { "[switchgate].passing",             "gate.wav"                      },
165   { "timegate_switch.activating",       "deng.wav"                      },
166   { "timegate_switch.active",           "miep.wav"                      },
167   { "timegate_switch.deactivating",     UNDEFINED_FILENAME              },
168   { "timegate.opening",                 "oeffnen.wav"                   },
169   { "[timegate].closing",               "oeffnen.wav"                   },
170   { "[timegate].passing",               "gate.wav"                      },
171   { "[conveyor_belt_switch].activating",UNDEFINED_FILENAME              },
172   { "[conveyor_belt].active",           UNDEFINED_FILENAME              },
173   { "[conveyor_belt_switch].deactivating",UNDEFINED_FILENAME            },
174   { "light_switch.activating",          UNDEFINED_FILENAME              },
175   { "light_switch.deactivating",        UNDEFINED_FILENAME              },
176
177   /* sounds for DX Boulderdash style elements and actions */
178   { "dx_supabomb.pushing",              "pusch.wav"                     },
179   { "trap.digging",                     "schlurf.wav"                   },
180   { "trap.activating",                  UNDEFINED_FILENAME              },
181   { "[tube].walking",                   UNDEFINED_FILENAME              },
182
183   /* sounds for Rocks'n'Diamonds style elements and actions */
184   { "amoeba.turning_to_gem",            "pling.wav"                     },
185   { "amoeba.turning_to_rock",           "klopf.wav"                     },
186   { "speed_pill.collecting",            "pong.wav"                      },
187   { "dynabomb_increase_number.collecting","pong.wav"                    },
188   { "dynabomb_increase_size.collecting","pong.wav"                      },
189   { "dynabomb_increase_power.collecting","pong.wav"                     },
190   { "[dynabomb].dropping",              "deng.wav"                      },
191   { "[dynabomb].active",                "zisch.wav"                     },
192   { "satellite.moving",                 UNDEFINED_FILENAME              },
193   { "satellite.waiting",                UNDEFINED_FILENAME              },
194   { "satellite.pushing",                "pusch.wav"                     },
195   { "lamp.activating",                  "deng.wav"                      },
196   { "lamp.deactivating",                "deng.wav"                      },
197   { "time_orb_full.collecting",         "gong.wav"                      },
198   { "time_orb_full.impact",             "deng.wav"                      },
199   { "time_orb_empty.pushing",           "pusch.wav"                     },
200   { "time_orb_empty.impact",            "deng.wav"                      },
201   { "game_of_life.waiting",             UNDEFINED_FILENAME              },
202   { "game_of_life.growing",             "amoebe.wav"                    },
203   { "biomaze.waiting",                  UNDEFINED_FILENAME              },
204   { "biomaze.growing",                  "amoebe.wav"                    },
205   { "pacman.moving",                    UNDEFINED_FILENAME              },
206   { "pacman.waiting",                   UNDEFINED_FILENAME              },
207   { "pacman.digging",                   UNDEFINED_FILENAME              },
208   { "dark_yamyam.moving",               UNDEFINED_FILENAME              },
209   { "dark_yamyam.waiting",              "njam.wav"                      },
210   { "dark_yamyam.digging",              UNDEFINED_FILENAME              },
211   { "penguin.moving",                   UNDEFINED_FILENAME              },
212   { "penguin.waiting",                  UNDEFINED_FILENAME              },
213   { "pig.moving",                       UNDEFINED_FILENAME              },
214   { "pig.waiting",                      UNDEFINED_FILENAME              },
215   { "pig.digging",                      UNDEFINED_FILENAME              },
216   { "dragon.moving",                    UNDEFINED_FILENAME              },
217   { "dragon.waiting",                   UNDEFINED_FILENAME              },
218   { "dragon.attacking",                 UNDEFINED_FILENAME              },
219
220   /* sounds not associated to game elements (used for menu screens etc.) */
221   /* keyword to stop parser: "NO_MORE_ELEMENT_SOUNDS" <-- do not change! */
222
223   /* sounds for other game actions */
224   { "game.starting",                    UNDEFINED_FILENAME              },
225   { "game.running_out_of_time",         "gong.wav"                      },
226   { "game.leveltime_bonus",             "sirr.wav"                      },
227   { "game.losing",                      "lachen.wav"                    },
228   { "game.winning",                     UNDEFINED_FILENAME              },
229   { "game.sokoban_solving",             "buing.wav"                     },
230
231   /* sounds for other non-game actions */
232   { "door.opening",                     "oeffnen.wav"                   },
233   { "door.closing",                     "oeffnen.wav"                   },
234
235   { "background.MAIN",                  UNDEFINED_FILENAME              },
236   { "background.LEVELS",                UNDEFINED_FILENAME              },
237   { "background.SCORES",                "halloffame.wav"                },
238   { "background.SCORES.mode_loop",      "false"                         },
239   { "background.EDITOR",                UNDEFINED_FILENAME              },
240   { "background.INFO",                  UNDEFINED_FILENAME              },
241   { "background.SETUP",                 UNDEFINED_FILENAME              },
242
243 #if 0
244   { "[not used]",                       "antigrav.wav"                  },
245   { "[not used]",                       "bong.wav"                      },
246   { "[not used]",                       "fuel.wav"                      },
247   { "[not used]",                       "holz.wav"                      },
248   { "[not used]",                       "hui.wav"                       },
249   { "[not used]",                       "kabumm.wav"                    },
250   { "[not used]",                       "kink.wav"                      },
251   { "[not used]",                       "kling.wav"                     },
252   { "[not used]",                       "krach.wav"                     },
253   { "[not used]",                       "laser.wav"                     },
254   { "[not used]",                       "quiek.wav"                     },
255   { "[not used]",                       "rumms.wav"                     },
256   { "[not used]",                       "schlopp.wav"                   },
257   { "[not used]",                       "schrff.wav"                    },
258   { "[not used]",                       "schwirr.wav"                   },
259   { "[not used]",                       "slurp.wav"                     },
260   { "[not used]",                       "sproing.wav"                   },
261   { "[not used]",                       "warnton.wav"                   },
262   { "[not used]",                       "whoosh.wav"                    },
263   { "[not used]",                       "boom.wav"                      },
264 #endif
265
266   { NULL,                               NULL                            }
267 };