How to animate shock absorbers in legs

Hi I’m rigging a robot that has shock absorbers in its legs. The leg also needs to bend at the knee like a normal leg. I know how to make a piston but the objects in a piston don’t have directly parented bones. My idea was to make dividing bones and then animate them extending and shortening.

Is this the right direction and if so, how can I do this? If not, what is a good way to do this?

Thank you

Attachments



I learned how to model a hydrolic piston that does what you want by watching this video…

essentially, you need to use a Damped Tracking constraint to get the one part to always point towards the other part, even though they aren’t connected.

Now that you put it like that I can see how a piston rig would work. Thanks for clarifying!

Glad I could help. The method used in the video also requires using an empty as the object to point at, iirc.