Hello everyone!
I need to set value of variable declared in script from C++ side.
The declaration is:
class MyClass
{
bool a;
int b;
float c;
};
MyClass asObj1;
There is a bit complex way of iterating object's properties and setting each manually. That's tough.
I need simpler way, possibly using copy constructor or operator.
Reading of this forum and documentation gives me two possible functions:
int asIScriptEngine::AssignScriptObject
And using asIScriptObject:
asIScriptModule::GetAddressOfGlobalVar
But i can't find exact solution.