X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Ftools.c;h=9aea7b4c7fcc64e29f951c2d214a1c4b365d79bb;hb=2d603d06ca862f3ca0721b66f62da188faf866c4;hp=801eb6b5b7f9c6e432d964407afe5c30b7565ecc;hpb=e788c9b6a44d9f2dea7aa048b48a11b14761229e;p=rocksndiamonds.git diff --git a/src/tools.c b/src/tools.c index 801eb6b5..9aea7b4c 100644 --- a/src/tools.c +++ b/src/tools.c @@ -2100,9 +2100,10 @@ unsigned int MoveDoor(unsigned int door_state) { if (!(door_state & DOOR_NO_DELAY)) { + /* opening door sound has priority over simultaneously closing door */ if (door_state & (DOOR_OPEN_1 | DOOR_OPEN_2)) PlaySoundStereo(SND_MENU_DOOR_OPENING, SOUND_MAX_RIGHT); - if (door_state & (DOOR_CLOSE_1 | DOOR_CLOSE_2)) + else if (door_state & (DOOR_CLOSE_1 | DOOR_CLOSE_2)) PlaySoundStereo(SND_MENU_DOOR_CLOSING, SOUND_MAX_RIGHT); }