If the compass needle moves, the ball contains an object that is magnetic.
(the ball; contains; an object that is magnetic) (an object; is; magnetic)
the ball an object
contains is
an object that is magnetic
magnetic