- started with a ScriptUtil class which will allow moving function implementations for ACS and FraggleScript to zscript.txt

So far 3 functions for testing implemented.
This commit is contained in:
Christoph Oelckers 2018-11-24 13:06:01 +01:00
commit 6fc63b9b78
10 changed files with 280 additions and 130 deletions

View file

@ -675,6 +675,23 @@ VMFunction *FindVMFunction(PClass *cls, const char *name);
FString FStringFormat(VM_ARGS, int offset = 0);
#define IFVM(cls, funcname) \
static VMFunction * func = nullptr; \
if (func == nullptr) { \
func = dyn_cast<PFunction>(RUNTIME_CLASS(cls)->FindSymbol(#funcname, false)); \
assert(func); \
} \
if (func != nullptr)
#define IFVMNAME(cls, funcname) \
static VMFunction * func = nullptr; \
if (func == nullptr) { \
func = dyn_cast<PFunction>(PClass::FindClass(cls)->FindSymbol(#funcname, false)); \
assert(func); \
} \
if (func != nullptr)
unsigned GetVirtualIndex(PClass *cls, const char *funcname);