aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authoruruk2013-06-20 14:08:58 +0200
committeruruk2013-06-20 14:08:58 +0200
commit3946d0ed929069de3740c03180274e2db0555422 (patch)
tree1406cd9917109e4e1d9dbccdf9e5015c09a55844 /engines
parentfa10b10ec75b4916a96b0f82c6927befbc6c0f38 (diff)
downloadscummvm-rg350-3946d0ed929069de3740c03180274e2db0555422.tar.gz
scummvm-rg350-3946d0ed929069de3740c03180274e2db0555422.tar.bz2
scummvm-rg350-3946d0ed929069de3740c03180274e2db0555422.zip
AVALANCHE: Add class Avalot. Cosmetic modifications.
Diffstat (limited to 'engines')
-rw-r--r--engines/avalanche/avalanche.cpp50
-rw-r--r--engines/avalanche/avalanche.h3
-rw-r--r--engines/avalanche/avalot.cpp41
-rw-r--r--engines/avalanche/avalot.h46
-rw-r--r--engines/avalanche/module.mk1
5 files changed, 113 insertions, 28 deletions
diff --git a/engines/avalanche/avalanche.cpp b/engines/avalanche/avalanche.cpp
index d8a43ba2ad..6e57663d87 100644
--- a/engines/avalanche/avalanche.cpp
+++ b/engines/avalanche/avalanche.cpp
@@ -25,6 +25,9 @@
* Copyright (c) 1994-1995 Mike, Mark and Thomas Thurman.
*/
+#include "avalanche/avalanche.h"
+#include "avalanche/avalot.h"
+
#include "common/system.h"
#include "common/random.h"
#include "common/error.h"
@@ -33,19 +36,10 @@
#include "common/config-manager.h"
#include "common/textconsole.h"
-#include "avalanche/avalanche.h"
-
#include "engines/util.h"
namespace Avalanche {
- void avalot(Common::String arg) {
- warning("STUB: avalot()"); // That will be a class made from avalot9.cpp !!! - or something like that
- }
-
-
-
-
AvalancheEngine *AvalancheEngine::s_Engine = 0;
AvalancheEngine::AvalancheEngine(OSystem *syst, const AvalancheGameDescription *gd) : Engine(syst), _gameDescription(gd) {
@@ -98,6 +92,10 @@ namespace Avalanche {
const char AvalancheEngine::runcodes[2][3] = {"et", "Go"};
+
+
+ // The original ones were all commented out, so porbably there's no need
+ // of these two cursor functions at all. TODO: Remove later.
void AvalancheEngine::cursor_off() {
warning("STUB: cursor_off()");
}
@@ -106,6 +104,7 @@ namespace Avalanche {
warning("STUB: cursor_on()");
}
+ // Needed later.
void AvalancheEngine::quit() {
cursor_on();
}
@@ -115,11 +114,13 @@ namespace Avalanche {
return q;
}
+ // Needed in dos_shell(). TODO: Remove later.
Common::String AvalancheEngine::command_com() {
warning("STUB: command_com()");
return ("STUB: command_com()");
}
+ // Needed for run_avalot()'s errors. TODO: Remove later.
void AvalancheEngine::explain(byte error) {
warning("STUB: explain()");
}
@@ -180,14 +181,6 @@ namespace Avalanche {
warning("STUB: call_menu()");
}
- void AvalancheEngine::run_avalot() {
- bflight_on();
-
- avalot(Common::String(runcodes[first_time]) + arguments); // TODO: Check if parameteres are ever use and eventually remove them
- // If there's an error initalizing avalot, i'll handle it in there, not here
- first_time = false;
- }
-
void AvalancheEngine::run_the_demo() {
warning("STUB: run_the_demo()");
}
@@ -196,22 +189,33 @@ namespace Avalanche {
warning("STUB: dos_shell()");
}
- bool AvalancheEngine::keypressed1() {
+ // Getting used only in demo() / call_menu(). Going to be implemented at the same time with these.
+ bool AvalancheEngine::keypressed1() {
warning("STUB: keypressed1()");
return false;
}
+ // Same as keypressed1().
void AvalancheEngine::flush_buffer() {
warning("STUB: flush_buffer()");
}
+ // Same as keypressed1().
void AvalancheEngine::demo() {
warning("STUB: demo()");
}
-
+
+ void AvalancheEngine::run_avalot() {
+ bflight_on();
+
+ Avalot ava;
+ ava.run(Common::String(runcodes[first_time]) + arguments); // TODO: Check if parameteres are ever use and eventually remove them
+ // If there's an error initalizing avalot, i'll handle it in there, not here
+ first_time = false;
+ }
@@ -224,9 +228,6 @@ namespace Avalanche {
// From bootstrp:
- /*original_mode = mem[seg0040 * 0x49];
- getintvec(0x1c, old_1c);*/
-
first_time = true;
get_arguments();
@@ -261,11 +262,6 @@ namespace Avalanche {
- // _mouse = new MouseHandler(this);
-
- // Setup mixer
- syncSoundSettings();
-
return Common::kNoError;
}
diff --git a/engines/avalanche/avalanche.h b/engines/avalanche/avalanche.h
index e6148be780..fa87d8b60a 100644
--- a/engines/avalanche/avalanche.h
+++ b/engines/avalanche/avalanche.h
@@ -28,8 +28,9 @@
#ifndef AVALANCHE_H
#define AVALANCHE_H
-#include "engines/engine.h"
#include "avalanche/console.h"
+
+#include "engines/engine.h"
#include "engines/advancedDetector.h"
namespace Common {
diff --git a/engines/avalanche/avalot.cpp b/engines/avalanche/avalot.cpp
new file mode 100644
index 0000000000..e89fbe1dbb
--- /dev/null
+++ b/engines/avalanche/avalot.cpp
@@ -0,0 +1,41 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ *
+ */
+
+/*
+ * This code is based on the original source code of Lord Avalot d'Argent version 1.3.
+ * Copyright (c) 1994-1995 Mike, Mark and Thomas Thurman.
+ */
+
+#include "common/str.h"
+#include "common/textconsole.h"
+
+#include "avalanche/avalot.h"
+
+namespace Avalanche {
+
+ Avalot::Avalot() {}
+
+ void Avalot::run(Common::String arg) {
+ warning("STUB: Avalot::run()");
+ }
+
+} // End of namespace Avalanche
diff --git a/engines/avalanche/avalot.h b/engines/avalanche/avalot.h
new file mode 100644
index 0000000000..84c96b4f6e
--- /dev/null
+++ b/engines/avalanche/avalot.h
@@ -0,0 +1,46 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ *
+ */
+
+/*
+ * This code is based on the original source code of Lord Avalot d'Argent version 1.3.
+ * Copyright (c) 1994-1995 Mike, Mark and Thomas Thurman.
+ */
+
+#ifndef AVALOT_H
+#define AVALOT_H
+
+#include "common/str.h"
+
+namespace Avalanche {
+
+class Avalot {
+private:
+
+public:
+ Avalot();
+
+ void run(Common::String arg);
+};
+
+} // End of namespace Avalanche
+
+#endif // AVALOT_H
diff --git a/engines/avalanche/module.mk b/engines/avalanche/module.mk
index 4db7160d68..8a83129a7d 100644
--- a/engines/avalanche/module.mk
+++ b/engines/avalanche/module.mk
@@ -2,6 +2,7 @@ MODULE := engines/avalanche
MODULE_OBJS = \
avalanche.o \
+ avalot.o \
console.o \
detection.o