I'm wanting to make an object bounce off an object yet it bounces in unwanted direction.

I want to make the ball that I have named ball_mc bounce off the posts and bars. I want the ball_mc to bounce off the leftpost_mc in a left direction, the ball_mc bounce off rightpost_mc in a right direction, and the ball_mc bounce off the bar_mc in an upward direction. I can't seem to figure this out and the ball bounces in directions that don't make sense to me. Can someone troubleshoot this for me.
This is what I've got so far.

Is this completely wrong?