You need to log in to create posts and topics.

Type "string" in property for scripted component

There seems to be an error for scripted component. When adding a property of type string. Unable to modify the value of the property. The modification is immediately canceled in the dialog box.

In the .mcu file:

	<propertygroup name="group name">
		<property name="Test" type="string" />
	</propertygroup>
	

 

In the .as file:

string test_string = "abcd";

string getTest() {
	return test_string;
}

void setTest( string &in val ) {
	test_string = val;
}

 

 

 

Sorry I missed this one, I will have a look.

Hi.

This works for me:

string test_string = "abcd";

string getTest()
{
    return test_string;
}

void setTest( string val )
{
    test_string = val;
    print( "setTest "+val );
}