I have one problem to solve. I am currently working on 2D animation in which I have to solve problem of bulldozer truck movement, and also movements of joints of the arm. I know how to animate rotating wheels by using this expression which i apply on rotation property of the wheel.
So now I have to find solution how to animate truck rotation of some vehicle in my situation it's bulldozer but it can be tank or some other... Here is the picture, and also I need the best way to animate arm movement, so it imitate sand digging in most "natural" way.
(This is sample picture of my 2D work that I need to animate. there is about 37 yellow triangles that represent bulldozer trucks. I need solution how to make them move (rotate) along the path and if possible how to write expression to avoid key-framing. I have created this picture in Illustrator and every single triangle is on separate layer)
Also if someone has ideas for how to animate sand movement during digging it would be great.
For the rotating bulldozer tracks I would think you'd animate one triangle along a path, offset the timing with and expressions using layer index (index*full circle/30) and then duplicate the layer 29 times. Also, there needs to be a modulo to put the triangle back at the beginning of the path when it reaches the end. I'd check for "animating an object along a path" to get started.
Arm movement like this is probably best done with a simple rotation animation. (I was about to suggest DUIK tools for inverse kinematics but a mechanical arm will likely look more correct with mechanical rotations rather than IK.)
Sand movement is pretty tricky. I'd just cut the sand into the shapes that you will expect to lift or move and animate those by hand as the scoop hits them. Sand (especially if it is somewhat wet) forms clumps.
You could add a particle effect to simulate individual grains rolling off the contact point, i.e. you can connect a particle emitter to a null and a slider, the null controlling the position and the slider the amount of particles emitted. Then you can animate that effect on and off as needed.
I am not sure how to apply suggested expression, to be specific on which property,( I supposed position)? I try to solve these problem by creating mask with same shape as truck path and then I have copied mask path to triangles position properties (I also chang transform > auto orient > orient along path). But that solving the problem only for one triangle If i repeat proces on other triangles i end up with bunch of triangles on one spot making a circle because of same keyframe properties that I have apply. If you have some more time to reply and try to explain me how to offset the timing with and expressions using layer index (index*full circle/30) I'd appreciate.
Since there are 30 pieces that make one full cycle around the track, the idea is to make the track consist of 30 layers, each with an offset of 1/30th of a full cycle. Layer index numbers can be used for this, doesn't even matter which layer numbers they are for this purpose as any adjacent 30 layers would fill the track. So, whatever property you are using to rotate one piece around the track would be offset by 3.3333% (=1/30) times the layer number. Except that when you go over 100, you'd have to cycle back to 0, thus you need a modulo, that is, the remainder from dividing by 100.
In pseudo code:
(position + 3.33333 * layer index) % 100
"position" here refers to whatever property value it is that you use for rotating around the track, which I don't remember off the top of my head. It would correlate to the expression you are using to rotate the rollers themselves; it is some fraction thereof.