Due to the fact that there are so many "randomly animated" aspects in the program, i'm trying to find an abstraction for those:
"Changeable" Properties are abstracted by an object (lets call the parent class MUTARE)
The object encapsulates one property (a number, a 2d position, a value from a discrete liste, ...) and its behaviour while time progresses.
each mutare has an update() method, which may (or may not) update the internal state (and gets called from the painter - or maybe some global mechanism where objects get registered (and also un-) automatically
the getValue() method yields the current value
So far i have identified the following types:
a number, randomly chosen from an interval after a number of update()'s
same as above, but the number does not "jump" but rather selects a new "target value" to which it is interpolated in a number of time steps (different interpolation methods? linear/curves)
an integral number, randomly chosen from an interval (this can also be done to select e.g. from a list of 3 items (get number between 0-2)
Due to the fact that there are so many "randomly animated" aspects in the program, i'm trying to find an abstraction for those:
"Changeable" Properties are abstracted by an object (lets call the parent class MUTARE) The object encapsulates one property (a number, a 2d position, a value from a discrete liste, ...) and its behaviour while time progresses.
So far i have identified the following types: