aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoseph-Eugene Winzer2017-08-31 21:17:40 +0200
committerThierry Crozat2018-01-23 02:15:25 +0000
commit142e1743ced232e2f269615c93ce0bbc3974144e (patch)
treee6fa51cea52467e6073fc44852a988904bedadea
parent749fa6336e97ade41bfb846d35115ed2db7c4141 (diff)
downloadscummvm-rg350-142e1743ced232e2f269615c93ce0bbc3974144e.tar.gz
scummvm-rg350-142e1743ced232e2f269615c93ce0bbc3974144e.tar.bz2
scummvm-rg350-142e1743ced232e2f269615c93ce0bbc3974144e.zip
SUPERNOVA: Fixes playing vinyl in CabinL3
-rw-r--r--engines/supernova/rooms.cpp48
-rw-r--r--engines/supernova/state.h1
2 files changed, 16 insertions, 33 deletions
diff --git a/engines/supernova/rooms.cpp b/engines/supernova/rooms.cpp
index ba6f6538fe..2c87b5869b 100644
--- a/engines/supernova/rooms.cpp
+++ b/engines/supernova/rooms.cpp
@@ -792,44 +792,28 @@ bool ShipCabinL3::interact(Action verb, Object &obj1, Object &obj2) {
} else if ((verb == ACTION_PRESS) && (obj1._id == TURNTABLE_BUTTON)) {
if (!isSectionVisible(15)) {
_vm->renderMessage("Es ist doch gar keine Platte aufgelegt.");
- } else if (!isSectionVisible(10) &&
- !isSectionVisible(11) &&
- isSectionVisible(12)) {
- if (_gm->_soundDevice != 2) {
- _gm->drawImage(14);
- setSectionVisible(15, false);
- for (int i = 3; i; i--) {
- _vm->playSound(kAudioTurntable);
- if (_gm->_soundDevice) {
- do {
- if (isSectionVisible(13)) {
- _gm->drawImage(14);
- setSectionVisible(13, false);
- } else {
- _gm->drawImage(13);
- setSectionVisible(14, false);
- }
- _gm->wait2(3);
- } while (_gm->_status);
+ } else if (!isSectionVisible(10) && !isSectionVisible(11) && isSectionVisible(12)) {
+ _gm->drawImage(14);
+ setSectionVisible(15, false);
+ for (int i = 3; i; i--) {
+ _vm->playSound(kAudioTurntable);
+ while (_vm->_mixer->isSoundHandleActive(_vm->_soundHandle)) {
+ if (isSectionVisible(13)) {
+ _gm->drawImage(14);
+ setSectionVisible(13, false);
} else {
- _gm->wait2(1);
+ _gm->drawImage(13);
+ setSectionVisible(14, false);
}
- }
- } else {
- for (int i = 10; i; i--) {
- _gm->drawImage(14);
- _gm->wait2(3);
- _gm->drawImage(13);
_gm->wait2(3);
}
}
- _gm->drawImage(15);
- setSectionVisible(14, false);
- setSectionVisible(13, false);
- _vm->renderMessage("Die Platte scheint einen Sprung zu haben.");
}
- } else if ((verb == ACTION_TAKE) && (obj1._id == RECORD) &&
- (obj1._click != 15)) {
+ _gm->drawImage(15);
+ setSectionVisible(14, false);
+ setSectionVisible(13, false);
+ _vm->renderMessage("Die Platte scheint einen Sprung zu haben.");
+ } else if ((verb == ACTION_TAKE) && (obj1._id == RECORD) && (obj1._click != 15)) {
_gm->drawImage(9);
setSectionVisible(13, false);
setSectionVisible(14, false);
diff --git a/engines/supernova/state.h b/engines/supernova/state.h
index 1ffa2d09c6..5d93961f0c 100644
--- a/engines/supernova/state.h
+++ b/engines/supernova/state.h
@@ -113,7 +113,6 @@ public:
Room *_rooms[NUMROOMS];
Inventory _inventory;
GameState _state;
- int _status;
bool _processInput;
bool _guiEnabled;
bool _animationEnabled;