Discrete Progress
SmartUI Discrete-Progress Behavior operation and ACEs.
Similarly to radio-buttons, it operates within the same context, whether it's the global container or lower-level containers created in the scene. Group all the Discrete Progress parts inside a container by adding them as children of the container. SmartUI will automatically determine the group they belong to.
Discrete-Progress uses the document flow together with the Part Sequence property to determine the order in which the parts will be filled.
All parts with the same part-sequence have the same priority for access by the framework. At this point, the document flow determines which part is processed first.
The Discrete Progress behavior iterates over an array of animations for the sprite to assign the active animation. Each part or sprite in the group can have a different number of subdivisions to represent the value. For instance, you can combine life hearts with pie or pizza slices to represent the value.
In this example, the number 9 is distributed among the different parts of the Discrete Progress group.
The hearts have 2 parts, and the pie has 6 parts. The value is distributed across all the available sprites.
A key attribute for this behavior is the animations, which require an ordered list of the animation names, separated by commas. Animation names are case-sensitive and must exactly match the names in your Sprite.
As you can imagine, the order to represent a value from 0 to 2 in above images is:
empty animation is for Zero
half animation is for 1.
full animation is for 2.
Properties
Smart UI Discrete Progress Part behavior handles progress parts UI components. If you use it as part of a hierarcy, you must add it to an object using a Smart UI Container behavior to be rendered correctly, since it will use its parent to determine the total Discrete Progress Part components available to alter.
Actions
Set Enabled
Set Enabled
Disable/Enable the Component
Set Name
Set Name
Sets the name of the component.
Set Part Sequence
Set Part Sequence
Sets the parts sequence index for this component.
Set Max Parts
Set Max Parts
Sets the maximum parts for this component.
Set Group Value
Set Group Value
Sets the value to be distributed among the parts of the same group. The group is determined by the container to which the parts belong.
Conditions
Is Enabled
Is Enabled
Returns true if the component is enabled
Compare Value
Compare Value
Compares the value of the part.
Compare Name
Compare Name
Returns true if the radio button components name equals the parameter
On Value Change
On Value Change
Triggered when the part value changes.
Expressions
Value
Value
Part current value.
MaxParts
MaxParts
Maximum parts for this component.
Name
Name
Component name
(c) Pixel Perfect Studio 2024
Last updated