mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-19 23:23:52 +00:00
Merge branch 'script' into xdoty
This commit is contained in:
commit
eb0be10e80
3 changed files with 18 additions and 1 deletions
|
@ -146,4 +146,5 @@ op 0x200014f: ForceGreeting
|
|||
op 0x2000150: ForceGreeting, explicit reference
|
||||
op 0x2000151: ToggleFullHelp
|
||||
op 0x2000152: Goodbye
|
||||
op 0x2000153: DontSaveObject (left unimplemented)
|
||||
opcodes 0x2000154-0x3ffffff unused
|
||||
|
|
|
@ -194,6 +194,17 @@ namespace MWScript
|
|||
}
|
||||
};
|
||||
|
||||
class OpDontSaveObject : public Interpreter::Opcode0
|
||||
{
|
||||
public:
|
||||
|
||||
virtual void execute (Interpreter::Runtime& runtime)
|
||||
{
|
||||
// We are ignoring the DontSaveObject statement for now. Probably not worth
|
||||
/// bothering with. The incompatibility we are creating should be marginal at most.
|
||||
}
|
||||
};
|
||||
|
||||
const int opcodeXBox = 0x200000c;
|
||||
const int opcodeOnActivate = 0x200000d;
|
||||
const int opcodeActivate = 0x2000075;
|
||||
|
@ -208,6 +219,7 @@ namespace MWScript
|
|||
const int opcodeFadeTo = 0x200013e;
|
||||
const int opcodeToggleWater = 0x2000144;
|
||||
const int opcodeTogglePathgrid = 0x2000146;
|
||||
const int opcodeDontSaveObject = 0x2000153;
|
||||
|
||||
void registerExtensions (Compiler::Extensions& extensions)
|
||||
{
|
||||
|
@ -229,6 +241,7 @@ namespace MWScript
|
|||
extensions.registerInstruction ("twa", "", opcodeToggleWater);
|
||||
extensions.registerInstruction ("togglepathgrid", "", opcodeTogglePathgrid);
|
||||
extensions.registerInstruction ("tpg", "", opcodeTogglePathgrid);
|
||||
extensions.registerInstruction ("dontsaveobject", "", opcodeDontSaveObject);
|
||||
}
|
||||
|
||||
void installOpcodes (Interpreter::Interpreter& interpreter)
|
||||
|
@ -247,6 +260,7 @@ namespace MWScript
|
|||
interpreter.installSegment5 (opcodeFadeTo, new OpFadeTo);
|
||||
interpreter.installSegment5 (opcodeTogglePathgrid, new OpTogglePathgrid);
|
||||
interpreter.installSegment5 (opcodeToggleWater, new OpToggleWater);
|
||||
interpreter.installSegment5 (opcodeDontSaveObject, new OpDontSaveObject);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -368,8 +368,10 @@ namespace Compiler
|
|||
special = S_cmpEQ;
|
||||
else
|
||||
{
|
||||
special = S_cmpEQ;
|
||||
putback (c);
|
||||
return false;
|
||||
// return false;
|
||||
// Allow = as synonym for ==. \todo optionally disable for post-1.0 scripting improvements.
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue