Closed dandaka closed 8 years ago
Hi @dandaka, I'm sorry but ani does not work with arrays. The only "shortcut syntax" is http://benedikt-gross.de/libraries/Ani/examples/Ani_Propertylist/Ani_Propertylist.pde. This feature is not planned and to be hones I also don't find it useful. I would rather consider to refactor it to an array of objects, where the object holds "inside" the animation logic ... see http://benedikt-gross.de/libraries/Ani/examples/Ani_in_Classes/Ani_in_Classes.pde. All the best + good luck, B
Thank you for letting me know :+1:
Benedikt,
I'm trying to use Ani with Hype to animate things. But Hype is not relevant for this error. I can't get to animate variables inside an array in a class. Here is log and source code:
https://github.com/deepower/p-visuals/blob/8c3d50d65c14b95da7b7f238172f99dff8aa8d3f/hype_ani/hype_ani.pde#L41-L43
Same code works with a variable, but doesn't work with same variable inside an array. I expect
s.anims[s.apos]
has same value asalpha
, but it doesn't get affected by Ani.https://gist.github.com/dandaka/0f6eba3971db74ea938b
Any ideas how to fix that? Thank you!