28#ifndef WINTERMUTE_SCSCRIPT_H
29#define WINTERMUTE_SCSCRIPT_H
32#include "engines/wintermute/base/base.h"
33#include "engines/wintermute/base/scriptables/dcscript.h"
34#include "engines/wintermute/coll_templ.h"
35#include "engines/wintermute/persistent.h"
38class BaseScriptHolder;
52 bool copyParameters(
ScStack *stack);
61 bool canHandleEvent(
const char *eventName);
62 bool canHandleMethod(
const char *methodName);
63 bool createThread(
ScScript *original, uint32 initIP,
const char *eventName);
64 bool createMethodThread(
ScScript *original,
const char *methodName);
65 ScScript *invokeEventHandler(
const char *eventName,
bool unbreakable =
false);
68 void runtimeError(
const char *fmt, ...);
70 bool finish(
bool includingThreads =
false);
71 bool sleep(uint32 duration);
79 TScriptState _origState;
81 uint32 getFuncPos(
const char *name);
82 uint32 getEventPos(
const char *name);
83 uint32 getMethodPos(
const char *name);
91 uint32 externalsTable;
116 TExternalType returns;
118 TExternalType *params;
129 virtual bool executeInstruction();
134 bool create(
const char *filename,
byte *buffer, uint32 size,
BaseScriptHolder *owner);
148 uint32 _numExternals;
150 uint32 _numFunctions;
164 virtual void preInstHook(uint32 inst);
165 virtual void postInstHook(uint32 inst);
168 TOpcodesType _opcodesType;
169 void initOpcodesType();
170 uint32 decodeAltOpcodes(uint32 inst);
173 bool _enableFloatCompareWA{};
Definition: base_game.h:79
Definition: base_object.h:49
Definition: base_script_holder.h:37
Definition: script_engine.h:43
Definition: script_stack.h:41
Definition: script_value.h:42