Unity 2D movement top down Write our code for our Unity 2D top down player movement controllerįirst off click on your player game object. You should now have your player in the scene and should look something like this now.
Right click in the hierarchy again and create a new game object, rename it and call it Player. Adding our player to our scene: unity top down movement You now have a nice background in my case I have something that looks like this. In the inspector add a sprite renderer component.Ĭopy the following inspector settings, the most import settings is the position and the order in layer must be -100 so the background renders at the back of all your assets in your game scene.Īdd in your background image into the sprite slot and you are ready to go. On the left hand side in the Unity hierarchy right click and create a empty game object. If you don’t want to follow along on this page you can watch the video version below: Setting up our top down game scene Doing 2D top down movement in Unity for your player can easily be achieved with some basic Unity functions and a small script.įirst we just going to setup our project.