Simple Player Movement in Unity

To get our player moving within our scene I have applied a script to a cube. This script will hold all the actions related to the cube named “Player”

opening the Player script within an IDE will allow us to enter code to make our game and communicate within the unity menus

the highlighted are what help us use unity. Start class is called on when the script is enabled. this will define the start position of the cube

update will be called once per frame continuously

This is the result



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store