From 08df8dc2721808c7019f49d9051e2eebfe8dad9c Mon Sep 17 00:00:00 2001 From: Paul Gilbert Date: Mon, 6 Jul 2009 02:46:59 +0000 Subject: Bugfix for node enabling/disabling, which was previously allowing the player to walk through closed doors and into the walls svn-id: r42162 --- engines/cruise/ctp.cpp | 4 ++-- engines/cruise/function.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'engines') diff --git a/engines/cruise/ctp.cpp b/engines/cruise/ctp.cpp index be4639af4d..11d5f582ed 100644 --- a/engines/cruise/ctp.cpp +++ b/engines/cruise/ctp.cpp @@ -209,9 +209,9 @@ int setNodeState(int nodeIdx, int nodeState) { int oldState = walkboxState[nodeIdx]; if (nodeState == -1) - return + return oldState; - walkboxState[nodeIdx] = nodeState; + walkboxState[nodeIdx] = nodeState; return oldState; } diff --git a/engines/cruise/function.cpp b/engines/cruise/function.cpp index eab69c6846..d0443ef458 100644 --- a/engines/cruise/function.cpp +++ b/engines/cruise/function.cpp @@ -828,7 +828,7 @@ int16 Op_Preload(void) { } int16 Op_LoadCt(void) { - return initCt((char*)popPtr()); + return initCt((const char *)popPtr()); } int16 Op_EndAnim(void) { -- cgit v1.2.3