aboutsummaryrefslogtreecommitdiff
path: root/scumm/script_v5.cpp
diff options
context:
space:
mode:
authorMax Horn2003-05-23 00:22:41 +0000
committerMax Horn2003-05-23 00:22:41 +0000
commitedf5946c408efebda37d37b4814822fb9578b141 (patch)
tree4b589960a6e4040cb277c720586d2bd2e639ba43 /scumm/script_v5.cpp
parent47246c35b316adcdba95ec98b0552a895a988eb4 (diff)
downloadscummvm-rg350-edf5946c408efebda37d37b4814822fb9578b141.tar.gz
scummvm-rg350-edf5946c408efebda37d37b4814822fb9578b141.tar.bz2
scummvm-rg350-edf5946c408efebda37d37b4814822fb9578b141.zip
some well placed asserts (triggering any of those means with 99% a bug in some other place; so don't just remove the asserts if you trigger one of 'em!
svn-id: r7840
Diffstat (limited to 'scumm/script_v5.cpp')
-rw-r--r--scumm/script_v5.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/scumm/script_v5.cpp b/scumm/script_v5.cpp
index 13510af5be..757f073adc 100644
--- a/scumm/script_v5.cpp
+++ b/scumm/script_v5.cpp
@@ -2358,8 +2358,7 @@ void Scumm_v5::o5_walkActorToActor() {
int nr;
int nr2 = getVarOrDirectByte(0x80);
a = derefActorSafe(nr2, "o5_walkActorToActor");
- if (!a)
- return;
+ assert(a);
if (!a->isInCurrentRoom()) {
getVarOrDirectByte(0x40);
@@ -2375,8 +2374,7 @@ void Scumm_v5::o5_walkActorToActor() {
}
// warning("walk actor %d to actor %d", nr, nr2);
a2 = derefActorSafe(nr, "o5_walkActorToActor(2)");
- if (!a2)
- return;
+ assert(a2);
if (!a2->isInCurrentRoom()) {
fetchScriptByte();