aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/sherlock/detection.cpp7
-rw-r--r--engines/sherlock/detection_tables.h1
-rw-r--r--engines/sherlock/map.cpp3
-rw-r--r--engines/sherlock/scalpel/scalpel.cpp10
-rw-r--r--engines/sherlock/scene.cpp10
5 files changed, 25 insertions, 6 deletions
diff --git a/engines/sherlock/detection.cpp b/engines/sherlock/detection.cpp
index c38580af41..78ab33bfd0 100644
--- a/engines/sherlock/detection.cpp
+++ b/engines/sherlock/detection.cpp
@@ -123,6 +123,13 @@ bool Sherlock::SherlockEngine::hasFeature(EngineFeature f) const {
}
/**
+ * Returns whether the version is a demo
+ */
+bool Sherlock::SherlockEngine::getIsDemo() const {
+ return _gameDescription->desc.flags & ADGF_DEMO;
+}
+
+/**
* Return a list of savegames
*/
SaveStateList SherlockMetaEngine::listSaves(const char *target) const {
diff --git a/engines/sherlock/detection_tables.h b/engines/sherlock/detection_tables.h
index 260869660e..975b7323ec 100644
--- a/engines/sherlock/detection_tables.h
+++ b/engines/sherlock/detection_tables.h
@@ -84,6 +84,7 @@ static const SherlockGameDescription gameDescriptions[] = {
{
// Case of the Rose Tattoo - English CD
+ // Provided by dreammaster
{
"rosetattoo",
"CD",
diff --git a/engines/sherlock/map.cpp b/engines/sherlock/map.cpp
index ef262aabd3..e178dece0c 100644
--- a/engines/sherlock/map.cpp
+++ b/engines/sherlock/map.cpp
@@ -69,7 +69,8 @@ Map::Map(SherlockEngine *vm): _vm(vm), _topLine(SHERLOCK_SCREEN_WIDTH, 12) {
for (int idx = 0; idx < MAX_HOLMES_SEQUENCE; ++idx)
Common::fill(&_sequences[idx][0], &_sequences[idx][MAX_FRAME], 0);
- loadData();
+ if (!_vm->getIsDemo())
+ loadData();
}
/**
diff --git a/engines/sherlock/scalpel/scalpel.cpp b/engines/sherlock/scalpel/scalpel.cpp
index 0b7a9be278..8dc75c034f 100644
--- a/engines/sherlock/scalpel/scalpel.cpp
+++ b/engines/sherlock/scalpel/scalpel.cpp
@@ -215,9 +215,11 @@ void ScalpelEngine::initialize() {
_flags[3] = true; // Turn on Alley
_flags[39] = true; // Turn on Baker Street
+ if (!getIsDemo()) {
// Load the map co-ordinates for each scene and sequence data
_map->loadPoints(NUM_PLACES, &MAP_X[0], &MAP_Y[0], &MAP_TRANSLATE[0]);
_map->loadSequences(3, &MAP_SEQUENCES[0][0]);
+ }
// Load the inventory
loadInventory();
@@ -226,13 +228,19 @@ void ScalpelEngine::initialize() {
_talk->setSequences(&TALK_SEQUENCES[0][0], &STILL_SEQUENCES[0][0], MAX_PEOPLE);
// Starting scene
- _scene->_goToScene = 4;
+ if (getIsDemo())
+ _scene->_goToScene = 3;
+ else
+ _scene->_goToScene = 4;
}
/**
* Show the opening sequence
*/
void ScalpelEngine::showOpening() {
+ if (getIsDemo())
+ return;
+
if (!showCityCutscene())
return;
if (!showAlleyCutscene())
diff --git a/engines/sherlock/scene.cpp b/engines/sherlock/scene.cpp
index 0893afe4c4..ca9f19582c 100644
--- a/engines/sherlock/scene.cpp
+++ b/engines/sherlock/scene.cpp
@@ -457,10 +457,12 @@ bool Scene::loadScene(const Common::String &filename) {
_walkedInScene = false;
saves._justLoaded = false;
- // Reset the previous map location and position on overhead map
- map._oldCharPoint = _currentScene;
- map._overPos.x = map[_currentScene].x * 100 - 600;
- map._overPos.y = map[_currentScene].y * 100 + 900;
+ if (!_vm->getIsDemo()) {
+ // Reset the previous map location and position on overhead map
+ map._oldCharPoint = _currentScene;
+ map._overPos.x = map[_currentScene].x * 100 - 600;
+ map._overPos.y = map[_currentScene].y * 100 + 900;
+ }
events.clearEvents();
return flag;