So, I’m trying to create a blobby surface between two nCloth cells on page 23 of this tutorial, but I am getting syntax errors.
This is the expression:
If (particleId % 2 == 0 )
{
goalWeight0PP=1;
goalWeight1PP=0;
}
else
{
goalWeight0PP=0;
goalWeight1PP=1;
}
The errors I get are below:
dynExpression -s “If (particleId % 2 == 0 )
{
goalWeight0PP=1;
goalWeight1PP=0;
}
else
{
goalWeight0PP=0;
goalWeight1PP=1;
}” -c particleShape1;
// Error: goalWeight0PP=1; //
// Error: Line 2.16: Syntax error //
// Error: else //
// Error: Line 5.4: Syntax error //
// Error: }; //
// Error: Line 9.1: Syntax error //
// Error: } //
// Error: Line 10.1: Syntax error //