Getting the player to move in Unity

Deon Jr.
Mar 17, 2021

Day 3.

Moving the player with user input involves manipulation of the transform component.

Transform component
Moving the player right… Forever

The code above moves the player object but without stopping. Resulting in…

Goodbye

Now lets make it move to our input.

This allows us to get the Input from the built in direction controls to make the player move to our commands.

And now movement! In one direction at least. But adding the other directions is easy after you know how to do one.

Super happy about how this is going in such a short amount of time! And unlike previous courses I feel like I can do this on my own in future!

--

--