Help with expressions for polyplanes
Due to the fact that Windows Movie Maker cannot play 15 individual images from my HD per second (trying to do a real cartoon), I have turned to Maya. Basically, I have an unholy number of images that need to be played to create a cartoon animation. I have a total of 500 images my friend drew on my HD. I am wanting to stick each image on a plane and move it to create the illusion of animation.
Here's how it will hopefully work - There are 500 Pplanes in a row (on the X-axis) spaced .05 units away from each other. I have a camera in front of the first Pplane. On frame 1, all 500 Pplanes need to move forward (positively on the X-axis) .05 units. This needs to happen every frame. I could do this easily by grouping all 500 together and use the following expression -
group1.translateX = time + .05;
however, (here's the tricky part) the frontmost Pplane needs to be moved out of the way at the same time. I had planned to simply move it over 2 units on the Z-axis, but I don't know enough about expressions to do it. I thought I could use this expression for each Pplane...
(this exp. for Pplane1) ----- if (translateX >= 0) Pplane1.translateZ = 2
(this exp. for Pplane2) ----- if (translateX >= 0) Pplane2.translateZ = 2
...but unfortunately, the translateX NEVER CHANGES!!! This is because all 500 Pplanes are in a group and it is the group's translateX that is moving. Needless to say, I am stumped. I don't know what to do. I know exactly how to animate each one with keys properly, but I figure it would be faster to use expressions - even if I have to write one for each Pplane.