- implemented State as an actual native struct, so that its fields can be accessed from scripts.

- refactored state bitfield members into a flag word because the address of a bitfield cannot be taken, making such variables inaccessible to scripts.
- actually use PNativeStruct for representing native structs defined in a script.
This commit is contained in:
Christoph Oelckers 2016-11-21 21:34:34 +01:00
commit 135cfcf016
12 changed files with 102 additions and 65 deletions

View file

@ -658,6 +658,7 @@ static int funccmp(const void * a, const void * b)
//==========================================================================
void G_InitLevelLocalsForScript();
void P_InitPlayerForScript();
void P_InitStateForScript();
void InitThingdef()
{
@ -669,6 +670,7 @@ void InitThingdef()
G_InitLevelLocalsForScript();
P_InitPlayerForScript();
P_InitStateForScript();
FAutoSegIterator probe(CRegHead, CRegTail);