CANCapture Scripting
Registering object properties

Class member variables can be registered so that they can be directly accessed by the script without the need for any method calls.

struct MyStruct
{
int a;
};
r = engine->RegisterObjectProperty("mytype", "int a", offsetof(MyStruct,a)); assert( r >= 0 );

offsetof() is a macro declared in stddef.h header file.