aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorPaul Gilbert2016-12-08 20:03:28 -0500
committerPaul Gilbert2016-12-08 20:03:28 -0500
commita90a4c8bc2ff350d69dc43f99c880d493efeb211 (patch)
tree65906c9d5bd76c6def8e650c23b1f164e0299d81 /engines
parent6425913a9c840027a80adf05647fbba686584e95 (diff)
downloadscummvm-rg350-a90a4c8bc2ff350d69dc43f99c880d493efeb211.tar.gz
scummvm-rg350-a90a4c8bc2ff350d69dc43f99c880d493efeb211.tar.bz2
scummvm-rg350-a90a4c8bc2ff350d69dc43f99c880d493efeb211.zip
TITANIC: Fix leaving 2nd class suites
Diffstat (limited to 'engines')
-rw-r--r--engines/titanic/core/game_object.cpp8
-rw-r--r--engines/titanic/moves/enter_sec_class_state.cpp2
2 files changed, 5 insertions, 5 deletions
diff --git a/engines/titanic/core/game_object.cpp b/engines/titanic/core/game_object.cpp
index 3a5f6567a6..48cc5206fd 100644
--- a/engines/titanic/core/game_object.cpp
+++ b/engines/titanic/core/game_object.cpp
@@ -867,10 +867,10 @@ CViewItem *CGameObject::parseView(const CString &viewString) {
// Ensure we have the specified room
if (project) {
- if (room->getName() != roomName) {
+ if (room->getName().compareToIgnoreCase(roomName)) {
// Scan for the correct room
for (room = project->findFirstRoom();
- room && room->getName() != roomName;
+ room && room->getName().compareToIgnoreCase(roomName);
room = project->findNextRoom(room)) ;
}
}
@@ -879,13 +879,13 @@ CViewItem *CGameObject::parseView(const CString &viewString) {
// Find the designated node within the room
CNodeItem *node = dynamic_cast<CNodeItem *>(room->findChildInstanceOf(CNodeItem::_type));
- while (node && node->getName() != nodeName)
+ while (node && node->getName().compareToIgnoreCase(nodeName))
node = dynamic_cast<CNodeItem *>(room->findNextInstanceOf(CNodeItem::_type, node));
if (!node)
return nullptr;
CViewItem *view = dynamic_cast<CViewItem *>(node->findChildInstanceOf(CViewItem::_type));
- while (view && view->getName() != viewName)
+ while (view && view->getName().compareToIgnoreCase(viewName))
view = dynamic_cast<CViewItem *>(node->findNextInstanceOf(CViewItem::_type, view));
if (!view)
return nullptr;
diff --git a/engines/titanic/moves/enter_sec_class_state.cpp b/engines/titanic/moves/enter_sec_class_state.cpp
index 853a00d590..af2bc4ac00 100644
--- a/engines/titanic/moves/enter_sec_class_state.cpp
+++ b/engines/titanic/moves/enter_sec_class_state.cpp
@@ -52,7 +52,7 @@ bool CEnterSecClassState::MouseButtonDownMsg(CMouseButtonDownMsg *msg) {
playSound("b#105.wav");
petDisplayMessage(1, CLASS_NOT_PERMITTED_IN_AREA);
} else if (!compareRoomNameTo("SecClassLittleLift") || _mode == 2) {
- CActMsg actMsg(getFullViewName().deleteRight(3) + ".S");
+ CActMsg actMsg(getFullViewName().deleteRight(2) + ".S");
actMsg.execute("SecClassRoomLeaver");
changeView("secClassState.Node 01.N");
}