The physics
A string cannot stretch. So write its length from the positions of the things tied to it. Then set that length equal to a constant.
one movable pulley: 2yB + yA = const → vB = −vA / 2
Take the rate of change once for velocities. Take it twice for accelerations. Measure every position from the same fixed line. Then the signs come out right by themselves.
Now pull a rope at an angle. Only the part of the velocity along the rope counts.
vrope = v cos θ
Two bodies in contact have equal velocities along the common normal. The normal is the line at right angles to the surface.