Change direction of an object 2d

Go to Google and type in the name of whatever game you are trying to copy / make along with the word ‘unity’ and you are almost certainly going to find a video showing exactly how to do what you want.

Otherwise, here is how to report your problem productively in the Unity3D forums:

http://plbm.com/?p=220

How to understand compiler and other errors and even fix them yourself:

If you post a code snippet, ALWAYS USE CODE TAGS:

How to use code tags: Using code tags properly