aboutsummaryrefslogtreecommitdiff
path: root/engines/sherlock/objects.h
diff options
context:
space:
mode:
authorPaul Gilbert2015-06-11 22:02:33 -0400
committerPaul Gilbert2015-06-11 22:02:33 -0400
commit3d0e2cb5b000bfa9ff731fc6a83ec402bd9f7aad (patch)
treef3780949461d600f733e33cea286f425d5f80619 /engines/sherlock/objects.h
parentf812447274fc1de46560e4e611c9d4cb9bf39beb (diff)
downloadscummvm-rg350-3d0e2cb5b000bfa9ff731fc6a83ec402bd9f7aad.tar.gz
scummvm-rg350-3d0e2cb5b000bfa9ff731fc6a83ec402bd9f7aad.tar.bz2
scummvm-rg350-3d0e2cb5b000bfa9ff731fc6a83ec402bd9f7aad.zip
SHERLOCK: Beginning of descendent Person classes
Tattoo has some different Sprite methods, and since Person descends from Sprite, need to create descendents from it. And this has also necessitated some refactoring of People class's _data array
Diffstat (limited to 'engines/sherlock/objects.h')
-rw-r--r--engines/sherlock/objects.h17
1 files changed, 11 insertions, 6 deletions
diff --git a/engines/sherlock/objects.h b/engines/sherlock/objects.h
index 6561a370fa..3c690e960f 100644
--- a/engines/sherlock/objects.h
+++ b/engines/sherlock/objects.h
@@ -92,6 +92,11 @@ enum {
#define TALK_LISTEN_CODE 251 // Code specifying start of talk listen frames in a Sequence
#define ALLOW_TALK_CODE 250
+#define UPPER_LIMIT 0
+#define LOWER_LIMIT (IS_SERRATED_SCALPEL ? CONTROLS_Y : SHERLOCK_SCREEN_HEIGHT)
+#define LEFT_LIMIT 0
+#define RIGHT_LIMIT SHERLOCK_SCREEN_WIDTH
+
class Point32 {
public:
int x;
@@ -217,7 +222,7 @@ public:
};
class Sprite: public BaseObject {
-private:
+protected:
static SherlockEngine *_vm;
/**
@@ -261,11 +266,6 @@ public:
void setImageFrame();
/**
- * This adjusts the sprites position, as well as it's animation sequence:
- */
- void adjustSprite();
-
- /**
* Checks the sprite's position to see if it's collided with any special objects
*/
void checkSprite();
@@ -299,6 +299,11 @@ public:
* in the sequence number uses alternate graphics, and if so if they need to be loaded
*/
void checkWalkGraphics();
+
+ /**
+ * This adjusts the sprites position, as well as it's animation sequence:
+ */
+ virtual void adjustSprite() = 0;
};
enum { OBJ_BEHIND = 1, OBJ_FLIPPED = 2, OBJ_FORWARD = 4, TURNON_OBJ = 0x20, TURNOFF_OBJ = 0x40 };