Little refactoring in VariablesSystem so it can also be used to evaluate anonymous expressions and conditions
Basic model (+engine) component that can holds an expression. Convenient for implementing a "conditioned visibility" component (next commit)
Reusable base system for conditions.
Adding support for conditioned visibility
- ModelEntities may contain "visbility" model components (Visibility), which just holds an expression that will condition the visibility of the entity on the screen (expression==true?visible:not_visible).
- Visibility components are transformed to VisibilityComponent in the engine through VisibilityProcessor.
- VisibilitySystem processes all VisibilityComponents, checking all the time if the expressions are met. VisibilitySystem extends ConditionalSystem
Simple VisibilityTest
Cool demo updated. A button that shows and hides the bee has been included
Adding conditions to timers. Test updated.
Adding conditions to touches. Have been refactored a little and now their implementation ressembles timers (RuntimeTouch added)
Adding support for conditional effects
Updating TouchesTest. Tests touches with conditions and also effects with conditions
(DOES NOT NEED TO BE REVIEWED) bindings.json
ConditionalSystem javadoc updated
Timer and touch doc improved
"expression" replaced by "condition" in conditionedcomponent. Avoids collision with changevar effect's expression. This fixes the cool demo
Minor improvement in variablessystem. Avoids multiple notifications for the same variable per cycle
Timers, Touches, Effects are not components anymore
Adding explicit dependency to VariablesSystem
bindings and other minor fixes
Merge pull request #354 from jtorrente/visibility-component

Condition support