From 9fdd43e25ee07123d8e2a245ababb14eb50c134e Mon Sep 17 00:00:00 2001 From: Travis Howell Date: Fri, 8 Oct 2004 00:37:29 +0000 Subject: Return 0 is array doesn't exist, possible script bug in HE game. svn-id: r15459 --- scumm/script_v72he.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'scumm') diff --git a/scumm/script_v72he.cpp b/scumm/script_v72he.cpp index e9d3aab82c..64b10096c7 100644 --- a/scumm/script_v72he.cpp +++ b/scumm/script_v72he.cpp @@ -898,6 +898,10 @@ void ScummEngine_v72he::o72_getArrayDimSize() { int subOp = fetchScriptByte(); int32 val1, val2; ArrayHeader *ah = (ArrayHeader *)getResourceAddress(rtString, readVar(fetchScriptWord())); + if (!ah) { + push(0); + return; + } switch (subOp) { case 1: -- cgit v1.2.3