Hi
I am trying to use getIdentifiedConstraint and getConstraint to get information about the constraints of a parameter. The ogScript-documentation is very scarce on information about these functions.
To take my problem for instance:
I have a integer-parameter with several constraints. It looks like this:
Value: 1 Name: abc
Value: 2 Name: xyz
I know the value I need to find within these constraints. What I am looking for is the "Name" of that value. I would think like this, but of course it doesn't work:
var value = this.getValue(); // Don't worry about how I know this
var allMyChoices = params.getConstraint (0x15);
var MySingeChoice = allMyChoices.getIdentifiedConstraint (value);
var myName = MySingleChoice.getValueAsString();
I know it may be hard to understand what I am trying to accomplish here, but a brief overview of how the constraint-scripting works would be appreciated :)