~ubuntu-branches/ubuntu/raring/scummvm/raring

« back to all changes in this revision

Viewing changes to engines/cruise/script.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Moritz Muehlenhoff
  • Date: 2011-05-25 19:02:23 UTC
  • mto: (21.1.2 sid)
  • mto: This revision was merged to the branch mainline in revision 24.
  • Revision ID: james.westby@ubuntu.com-20110525190223-fiqm0oaec714xk31
Tags: upstream-1.3.0
ImportĀ upstreamĀ versionĀ 1.3.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
 * along with this program; if not, write to the Free Software
19
19
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
20
20
 *
21
 
 * $URL: https://scummvm.svn.sourceforge.net/svnroot/scummvm/scummvm/tags/release-1-2-1/engines/cruise/script.cpp $
22
 
 * $Id: script.cpp 51834 2010-08-07 14:38:07Z athrxx $
 
21
 * $URL$
 
22
 * $Id$
23
23
 *
24
24
 */
25
25
 
26
26
#include "cruise/cruise.h"
27
27
#include "cruise/cruise_main.h"
28
28
#include "common/endian.h"
 
29
#include "common/textconsole.h"
29
30
 
30
31
namespace Cruise {
31
32
 
185
186
                        return 0;
186
187
                }
187
188
                case 2: {
 
189
                        assert (ptr);
188
190
                        *(ptr + var_A + offset) = var;
189
 
                        return (0);
 
191
                        return 0;
190
192
                }
191
193
                default:
192
194
                        error("Unsupported code in opcodeType1 case 1");
448
450
}
449
451
 
450
452
int32 opcodeType9() {           // stop script
451
 
        //printf("Stop a script of overlay %s\n",overlayTable[currentScriptPtr->overlayNumber].overlayName);
 
453
        //debug("Stop a script of overlay %s", overlayTable[currentScriptPtr->overlayNumber].overlayName);
452
454
        currentScriptPtr->scriptNumber = -1;
453
455
        return (1);
454
456
}
500
502
        int var_C;
501
503
        scriptInstanceStruct *oldTail;
502
504
 
503
 
        //printf("Starting script %d of overlay %s\n",param,overlayTable[overlayNumber].overlayName);
 
505
        //debug("Starting script %d of overlay %s", param,overlayTable[overlayNumber].overlayName);
504
506
 
505
507
        if (scriptType < 0) {
506
508
                useArg3Neg = 1;
618
620
        positionInStack = 0;
619
621
 
620
622
        do {
621
 
//#ifdef SKIP_INTRO
 
623
#ifdef SKIP_INTRO
622
624
                if (currentScriptPtr->scriptOffset == 290
623
625
                        && currentScriptPtr->overlayNumber == 4
624
626
                        && currentScriptPtr->scriptNumber == 0) {
625
627
                        currentScriptPtr->scriptOffset = 923;
626
628
                }
627
 
//#endif
 
629
#endif
628
630
                opcodeType = getByteFromScript();
629
631
 
630
632
                debugC(5, kCruiseDebugScript, "Script %s/%d ip=%d opcode=%d",