setStateTransitionProperty
setStateTransitionProperty
Changes a property value registered on a specific step among the steps that make up a State Transition. Use it to change a step's value dynamically before or during playback. Here index points to which step within the transition — a different meaning from the repeating-item index in startStateTransitionWithIndex — and property must be a property already configured on that step in Studio for the value to take effect; an arbitrary string won't apply.
Parameters
| Name | Type | Description |
|---|---|---|
transitionID | String | The id of the target state transition |
index | int | The index of the transition step whose value you're changing |
property | String | The name of the property to change. It must already be configured on that step to take effect |
value | dynamic | The new value to set |
Returns: void
Example
$act.setStateTransitionProperty("slideIn", 0, "opacity", 0.5);
Related
$act.startStateTransition(transitionID, onEnd, duration)— starts a transition$act.startStateTransitionWithIndex(transitionID, index, onEnd, duration)— starts a transition on one item only