diff options
Diffstat (limited to 'engines/titanic/moves')
-rw-r--r-- | engines/titanic/moves/move_player_in_parrot_room.cpp | 12 | ||||
-rw-r--r-- | engines/titanic/moves/move_player_in_parrot_room.h | 9 |
2 files changed, 6 insertions, 15 deletions
diff --git a/engines/titanic/moves/move_player_in_parrot_room.cpp b/engines/titanic/moves/move_player_in_parrot_room.cpp index 186e448bba..dfe8cf547e 100644 --- a/engines/titanic/moves/move_player_in_parrot_room.cpp +++ b/engines/titanic/moves/move_player_in_parrot_room.cpp @@ -27,6 +27,7 @@ namespace Titanic { BEGIN_MESSAGE_MAP(CMovePlayerInParrotRoom, CMovePlayerTo) ON_MESSAGE(ActMsg) ON_MESSAGE(MouseButtonDownMsg) + ON_MESSAGE(MovementMsg) END_MESSAGE_MAP() CMovePlayerInParrotRoom::CMovePlayerInParrotRoom() : CMovePlayerTo() { @@ -58,13 +59,10 @@ bool CMovePlayerInParrotRoom::MouseButtonDownMsg(CMouseButtonDownMsg *msg) { return true; } -bool CMovePlayerInParrotRoom::findPoint(Point &pt) { - if (_destination == "ParrotLobby.Node 1.E") { - pt = Point(600, 180); - return true; - } else { - return CMovePlayerTo::findPoint(pt); - } +bool CMovePlayerInParrotRoom::MovementMsg(CMovementMsg *msg) { + if (msg->_movement == TURN_RIGHT) + msg->_posToUse = Point(600, 180); + return false; } } // End of namespace Titanic diff --git a/engines/titanic/moves/move_player_in_parrot_room.h b/engines/titanic/moves/move_player_in_parrot_room.h index 50a0b2a00e..637c8b8211 100644 --- a/engines/titanic/moves/move_player_in_parrot_room.h +++ b/engines/titanic/moves/move_player_in_parrot_room.h @@ -31,6 +31,7 @@ class CMovePlayerInParrotRoom : public CMovePlayerTo { DECLARE_MESSAGE_MAP; bool ActMsg(CActMsg *msg); bool MouseButtonDownMsg(CMouseButtonDownMsg *msg); + bool MovementMsg(CMovementMsg *msg); public: CLASSDEF; CMovePlayerInParrotRoom(); @@ -44,14 +45,6 @@ public: * Load the data for the class from file */ virtual void load(SimpleFile *file); - - /** - * Returns a point that falls within the object. Used for simulating - * mouse clicks for movement when arrow keys are pressed - * @param pt Return point - * @returns True if a point was found - */ - virtual bool findPoint(Point &pt); }; } // End of namespace Titanic |