The impulse is passed from ball to ball until it reaches the free one at the other end which moves up by about the same amount as the initial strike. When it falls back the same happens in reverse. The ampitude slowly decreases due to air resistance and frictional losses.
They work pretty well up to speeds of c/10 or thereabouts and on scales from marbles up to solar systems so that isn't a bad range of validity.
People who drive one car length apart in the outside lane of motorways seem oblivious to the implications of Newton's laws and have a strange belief in instantaneous magical non-inertial braking.
Only when you get very close to the sun or near a black hole do you need to use the full GR treatment of gravity and conservation laws. You can do a simple perturbation of Newtonian dynamics for the sun or Jupiter.