aboutsummaryrefslogtreecommitdiff
path: root/engines/tsage
diff options
context:
space:
mode:
authorPaul Gilbert2011-05-14 18:19:35 +1000
committerPaul Gilbert2011-05-14 18:19:35 +1000
commit621a6e522948b35b7967c0f573c6008fc0fca078 (patch)
tree612ad942c57042ce2ed86fcbed5fb6a9584b7a26 /engines/tsage
parenta255461ab33e14dfacf399fcbac88e88c7a54d1f (diff)
downloadscummvm-rg350-621a6e522948b35b7967c0f573c6008fc0fca078.tar.gz
scummvm-rg350-621a6e522948b35b7967c0f573c6008fc0fca078.tar.bz2
scummvm-rg350-621a6e522948b35b7967c0f573c6008fc0fca078.zip
TSAGE: Added skeleton game class for Blue Force
Diffstat (limited to 'engines/tsage')
-rw-r--r--engines/tsage/blueforce_logic.cpp41
-rw-r--r--engines/tsage/blueforce_logic.h42
-rw-r--r--engines/tsage/globals.cpp19
3 files changed, 97 insertions, 5 deletions
diff --git a/engines/tsage/blueforce_logic.cpp b/engines/tsage/blueforce_logic.cpp
new file mode 100644
index 0000000000..27e8da2b96
--- /dev/null
+++ b/engines/tsage/blueforce_logic.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.
+ *
+ */
+
+#include "tsage/blueforce_logic.h"
+#include "tsage/scenes.h"
+#include "tsage/tsage.h"
+#include "tsage/staticres.h"
+
+namespace tSage {
+
+void BlueForceGame::start() {
+ // Start the game
+ _globals->_sceneManager.changeScene(1);
+
+ _globals->_events.setCursor(CURSOR_WALK);
+}
+
+Scene *BlueForceGame::createScene(int sceneNumber) {
+ error("TODO: Implement BlueForceGame::createScene");
+}
+
+} // End of namespace tSage
diff --git a/engines/tsage/blueforce_logic.h b/engines/tsage/blueforce_logic.h
new file mode 100644
index 0000000000..9237e50a13
--- /dev/null
+++ b/engines/tsage/blueforce_logic.h
@@ -0,0 +1,42 @@
+/* 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.
+ *
+ */
+
+#ifndef TSAGE_BLUEFORCE_LOGIC_H
+#define TSAGE_BLUEFORCE_LOGIC_H
+
+#include "common/scummsys.h"
+#include "tsage/events.h"
+#include "tsage/core.h"
+#include "tsage/scenes.h"
+#include "tsage/globals.h"
+
+namespace tSage {
+
+class BlueForceGame: public Game {
+public:
+ virtual void start();
+ virtual Scene *createScene(int sceneNumber);
+};
+
+} // End of namespace tSage
+
+#endif
diff --git a/engines/tsage/globals.cpp b/engines/tsage/globals.cpp
index bff1bdeaa6..e51e9d2be6 100644
--- a/engines/tsage/globals.cpp
+++ b/engines/tsage/globals.cpp
@@ -22,6 +22,7 @@
#include "tsage/globals.h"
#include "tsage/tsage.h"
+#include "tsage/blueforce_logic.h"
#include "tsage/ringworld_demo.h"
#include "tsage/ringworld_logic.h"
@@ -82,11 +83,19 @@ Globals::Globals() :
_scrollFollower = NULL;
_inventory = NULL;
- if (!(_vm->getFeatures() & GF_DEMO)) {
- _inventory = new RingworldInvObjectList();
- _game = new RingworldGame();
- } else {
- _game = new RingworldDemoGame();
+ switch (_vm->getGameID()) {
+ case GType_Ringworld:
+ if (!(_vm->getFeatures() & GF_DEMO)) {
+ _inventory = new RingworldInvObjectList();
+ _game = new RingworldGame();
+ } else {
+ _game = new RingworldDemoGame();
+ }
+ break;
+
+ case GType_BlueForce:
+ _game = new BlueForceGame();
+ break;
}
}