Inverse kinematics to allow the end of an articulated arm to follow the mouse pointer. Choose the number of segments. Grab the ball by moving the mouse pointer to it and click the mouse button to grab it. Try grabbing the ball while it's moving. Original project written to help with forum post - https://scratch.mit.edu/discuss/topic/718995/ According to Wikipedia: "Inverse Kinematics is the mathematical process of calculating the variable joint parameters needed to place the end of a kinematic chain, such as a robot manipulator or animation character's skeleton, in a given position and orientation relative to the start of the chain."
I remixed this to add a gripper at the end of the arm and something to grab. I also modified the calculations a little to allow an offset from 0,0. This version uses a different algorithm than the 2 and 3 segment Robot Arms. It uses an algorithm by @PullJosh. This project would not have been possible without it.