aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/hdb/hdb.cpp5
-rw-r--r--engines/hdb/hdb.h1
2 files changed, 4 insertions, 2 deletions
diff --git a/engines/hdb/hdb.cpp b/engines/hdb/hdb.cpp
index edf875a192..494d1166bd 100644
--- a/engines/hdb/hdb.cpp
+++ b/engines/hdb/hdb.cpp
@@ -44,6 +44,7 @@ HDBGame::HDBGame(OSystem *syst, const ADGameDescription *gameDesc) : Engine(syst
g_hdb = this;
_fileMan = new FileMan;
_lua = new LuaScript;
+ _map = new Map;
//mapLoader = new MapLoader;
DebugMan.addDebugChannel(kDebugExample1, "Example1", "This is just an example to test");
@@ -54,6 +55,7 @@ HDBGame::~HDBGame() {
delete _console;
delete _fileMan;
delete _lua;
+ delete _map;
//delete mapLoader;
DebugMan.clearAllDebugChannels();
}
@@ -156,8 +158,7 @@ Common::Error HDBGame::run() {
return Common::kReadingFailed;
}
- Map *map = new Map;
- map->load(mapStream);
+ _map->load(mapStream);
#if 0
lua->executeFile("test.lua");
diff --git a/engines/hdb/hdb.h b/engines/hdb/hdb.h
index 19f7156480..b31d9d7064 100644
--- a/engines/hdb/hdb.h
+++ b/engines/hdb/hdb.h
@@ -84,6 +84,7 @@ public:
FileMan *_fileMan;
LuaScript *_lua;
+ Map *_map;
// Game related members;