How to make an object move in one direction and make it change direction by touching it

I am new to unity and C# so I don’t really know much. I’ve searched but haven’t really found something useful.
I want to make my object (Ball) move at the start of the Game from top Left corner of the screen to either the right top corner or the bottom left corner. the same goes for the other corner aswell.

if ball is top left, it can only move right or down. so it doesnt hit the edges/walls.

How do I programm that? I hope I’ve told you enough to give me a good answer.

:slight_smile:

Good day.

As @eses says, you are asking multiple things in one question, and they are all very basic… So this means you should go spend 4-5 hours of your time for learning the basics of Unity and scripting. It’s very neccessary if you pretend to continue developing.

Goodbye!