If two balls are travelling to the same direction ,we take it as e(U1-U2)=(V1-V2)

if to the opposite direction we take it as e(U1+U2)=(V1+V2) .my question is ,where should we take this as e(U1-U2)=(V1-V2) if they are travelling to the same direction?(before and after the collision )