aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra/kyra_v2.h
diff options
context:
space:
mode:
authorJohannes Schickel2008-05-02 15:39:51 +0000
committerJohannes Schickel2008-05-02 15:39:51 +0000
commit5e4fceec2eb837257386f790d920eadf483da3cf (patch)
tree38f440c89b59dca258225d64c78b86e11c4954a9 /engines/kyra/kyra_v2.h
parentc6830b4138be54e056a7cf18b6b900c3e46ab4ff (diff)
downloadscummvm-rg350-5e4fceec2eb837257386f790d920eadf483da3cf.tar.gz
scummvm-rg350-5e4fceec2eb837257386f790d920eadf483da3cf.tar.bz2
scummvm-rg350-5e4fceec2eb837257386f790d920eadf483da3cf.zip
Moved some character code from kyra2/kyra3 to KyraEngine_v2.
svn-id: r31822
Diffstat (limited to 'engines/kyra/kyra_v2.h')
-rw-r--r--engines/kyra/kyra_v2.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/engines/kyra/kyra_v2.h b/engines/kyra/kyra_v2.h
index e15d0a7acd..c5be20e363 100644
--- a/engines/kyra/kyra_v2.h
+++ b/engines/kyra/kyra_v2.h
@@ -238,6 +238,35 @@ protected:
void setHandItem(uint16 item);
void removeHandItem();
+
+ // character
+ struct Character {
+ uint16 sceneId;
+ uint16 dlgIndex;
+ uint8 height;
+ uint8 facing;
+ uint16 animFrame;
+ byte walkspeed;
+ uint16 inventory[20];
+ int16 x1, y1;
+ int16 x2, y2;
+ int16 x3, y3;
+ };
+
+ Character _mainCharacter;
+ int _mainCharX, _mainCharY;
+ int _charScale;
+
+ void moveCharacter(int facing, int x, int y);
+ int updateCharPos(int *table, int force = 0);
+ void updateCharPosWithUpdate();
+
+ uint32 _updateCharPosNextUpdate;
+ static const int8 _updateCharPosXTable[];
+ static const int8 _updateCharPosYTable[];
+
+ virtual int getCharacterWalkspeed() const = 0;
+ virtual void updateCharAnimFrame(int num, int *table) = 0;
};
} // end of namespace Kyra