diff options
author | Paul Gilbert | 2016-06-23 21:22:59 -0400 |
---|---|---|
committer | Paul Gilbert | 2016-07-15 19:24:22 -0400 |
commit | 5b98885f8797d5c36336a22a9399611b11a3715f (patch) | |
tree | 48c087f9fa697bb5375c3d6ff0441f8d5343e8cc /engines/titanic/pet_control/pet_rooms_glyphs.h | |
parent | f7d6db05e849855cbd17a60c3bbc3b1e96d1453a (diff) | |
download | scummvm-rg350-5b98885f8797d5c36336a22a9399611b11a3715f.tar.gz scummvm-rg350-5b98885f8797d5c36336a22a9399611b11a3715f.tar.bz2 scummvm-rg350-5b98885f8797d5c36336a22a9399611b11a3715f.zip |
TITANIC: Figured out PET Room Glyph modes
Diffstat (limited to 'engines/titanic/pet_control/pet_rooms_glyphs.h')
-rw-r--r-- | engines/titanic/pet_control/pet_rooms_glyphs.h | 32 |
1 files changed, 26 insertions, 6 deletions
diff --git a/engines/titanic/pet_control/pet_rooms_glyphs.h b/engines/titanic/pet_control/pet_rooms_glyphs.h index cb937ec5c0..574403b0c6 100644 --- a/engines/titanic/pet_control/pet_rooms_glyphs.h +++ b/engines/titanic/pet_control/pet_rooms_glyphs.h @@ -28,7 +28,9 @@ namespace Titanic { -enum RoomGlyphMode { RGM_0 = 0, RGM_1 = 1, RGM_2 = 2 }; +enum RoomGlyphMode { + RGM_UNASSIGNED = 0, RGM_ASSIGNED_ROOM = 1, RGM_PREV_ASSIGNED_ROOM = 2 +}; class CPetRoomsGlyph : public CPetGlyph { private: @@ -75,6 +77,11 @@ public: virtual int proc29(const Point &pt); + /** + * Returns the tooltip text for when the glyph is selected + */ + virtual void getTooltip(CPetText *text); + virtual void save2(SimpleFile *file, int indent) const; virtual int proc33(); @@ -103,9 +110,20 @@ public: void changeLocation(int newClassNum); - bool isModeValid() const { return _mode != RGM_0; } - bool isMode1() const { return _mode == RGM_1; } - bool isMode2() const { return _mode == RGM_2; } + /** + * Returns true if the room is either currently or previously assigned + */ + bool isAssigned() const { return _mode != RGM_UNASSIGNED; } + + /** + * Returns true if the room is the one currently assigned to the player + */ + bool isCurrentlyAssigned() const { return _mode == RGM_ASSIGNED_ROOM; } + + /** + * Returns true if the room was previously assigned to the player + */ + bool isPreviouslyAssigned() const { return _mode == RGM_PREV_ASSIGNED_ROOM; } }; class CPetRoomsGlyphs : public CPetGlyphs { @@ -116,8 +134,10 @@ public: */ void save2(SimpleFile *file, int indent) const; - CPetRoomsGlyph *findMode1() const; - + /** + * Returns the glyph for hte player's assigned room + */ + CPetRoomsGlyph *findAssignedRoom() const; /** * Finds a glyph in the list by it's room flags |