aboutsummaryrefslogtreecommitdiff
path: root/engines/sherlock/scalpel
diff options
context:
space:
mode:
Diffstat (limited to 'engines/sherlock/scalpel')
-rw-r--r--engines/sherlock/scalpel/scalpel_people.cpp5
-rw-r--r--engines/sherlock/scalpel/scalpel_people.h5
-rw-r--r--engines/sherlock/scalpel/scalpel_scene.cpp1
3 files changed, 10 insertions, 1 deletions
diff --git a/engines/sherlock/scalpel/scalpel_people.cpp b/engines/sherlock/scalpel/scalpel_people.cpp
index 89f3eeaeb6..72d8d32812 100644
--- a/engines/sherlock/scalpel/scalpel_people.cpp
+++ b/engines/sherlock/scalpel/scalpel_people.cpp
@@ -334,6 +334,11 @@ void ScalpelPerson::setWalking() {
_frameNumber = oldFrame;
}
+Common::Point ScalpelPerson::getSourcePoint() const {
+ return Common::Point(_position.x / FIXED_INT_MULTIPLIER + frameWidth() / 2,
+ _position.y / FIXED_INT_MULTIPLIER);
+}
+
/*----------------------------------------------------------------*/
ScalpelPeople::ScalpelPeople(SherlockEngine *vm) : People(vm) {
diff --git a/engines/sherlock/scalpel/scalpel_people.h b/engines/sherlock/scalpel/scalpel_people.h
index 9d1214bc68..dc1258308f 100644
--- a/engines/sherlock/scalpel/scalpel_people.h
+++ b/engines/sherlock/scalpel/scalpel_people.h
@@ -42,6 +42,11 @@ enum ScalpelSequences {
};
class ScalpelPerson : public Person {
+protected:
+ /**
+ * Get the source position for a character potentially affected by scaling
+ */
+ virtual Common::Point getSourcePoint() const;
public:
ScalpelPerson() : Person() {}
virtual ~ScalpelPerson() {}
diff --git a/engines/sherlock/scalpel/scalpel_scene.cpp b/engines/sherlock/scalpel/scalpel_scene.cpp
index c4da8e09a0..723939211a 100644
--- a/engines/sherlock/scalpel/scalpel_scene.cpp
+++ b/engines/sherlock/scalpel/scalpel_scene.cpp
@@ -135,7 +135,6 @@ void ScalpelScene::drawAllShapes() {
screen.resetDisplayBounds();
}
-
void ScalpelScene::checkBgShapes() {
People &people = *_vm->_people;
Person &holmes = people[HOLMES];