aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStrangerke2014-12-04 01:21:23 +0100
committerPaul Gilbert2014-12-12 22:58:40 -0500
commit580fec468f61d8883ad0a78b27cc6555532b5803 (patch)
tree6855724aae6ecba28aa4e7fafdb97cc8460a0aee
parent771bcc8efd12d40c9ad13c270fe93567e093f329 (diff)
downloadscummvm-rg350-580fec468f61d8883ad0a78b27cc6555532b5803.tar.gz
scummvm-rg350-580fec468f61d8883ad0a78b27cc6555532b5803.tar.bz2
scummvm-rg350-580fec468f61d8883ad0a78b27cc6555532b5803.zip
ACCESS: Implement loadNSound, add a warning about another special opcode used by the demo
-rw-r--r--engines/access/amazon/amazon_scripts.cpp10
-rw-r--r--engines/access/amazon/amazon_scripts.h1
2 files changed, 10 insertions, 1 deletions
diff --git a/engines/access/amazon/amazon_scripts.cpp b/engines/access/amazon/amazon_scripts.cpp
index 80aded7983..43532aa93c 100644
--- a/engines/access/amazon/amazon_scripts.cpp
+++ b/engines/access/amazon/amazon_scripts.cpp
@@ -246,6 +246,11 @@ void AmazonScripts::loadBackground(int param1, int param2) {
_vm->_screen->forceFadeIn();
}
+void AmazonScripts::loadNSound(int param1, int param2) {
+ Resource *sound = _vm->_files->loadFile(param1, param2);
+ _vm->_sound->_soundTable.push_back(SoundEntry(sound, 1));
+}
+
void AmazonScripts::setInactive() {
_game->_rawInactiveX = _vm->_player->_rawPlayer.x;
_game->_rawInactiveY = _vm->_player->_rawPlayer.y;
@@ -314,6 +319,9 @@ void AmazonScripts::plotInactive() {
void AmazonScripts::executeSpecial(int commandIndex, int param1, int param2) {
switch (commandIndex) {
+ case 0:
+ warning("TODO: DEMO - RESETAN");
+ break;
case 1:
_vm->establish(param1, param2);
break;
@@ -328,7 +336,7 @@ void AmazonScripts::executeSpecial(int commandIndex, int param1, int param2) {
break;
case 4:
if (_vm->isDemo())
- warning("TODO: DEMO - LOADNSOUND");
+ loadNSound(param1, param2);
else
setInactive();
break;
diff --git a/engines/access/amazon/amazon_scripts.h b/engines/access/amazon/amazon_scripts.h
index 968d51e2c4..573ffb89bf 100644
--- a/engines/access/amazon/amazon_scripts.h
+++ b/engines/access/amazon/amazon_scripts.h
@@ -45,6 +45,7 @@ protected:
void mWhile(int param1);
void loadBackground(int param1, int param2);
void plotInactive();
+ void loadNSound(int param1, int param2);
void setInactive();
void boatWalls(int param1, int param2);