Controls and player movement
We are going to cover a couple of different control schemes, depending on the platform you want to release your awesome game on. We will deal with some keyboard controls, mouse controls, and even some touch controls for mobile devices.
Let's go into our project, and open up level 1.
- First we are going to add some gravity to the scene.
- In the scene editor, click on the Scene button in the Inspector window.
- In the Attributes window, expand the Gravity drop down, and change the Y value to
900
. - Now, on to our actor! We have already created our player actor in the Library, so let's drag him into our level.
- Once he's placed exactly where you want him to be, double-click on him to open up the actor editor. Instead of clicking the lock button, click the Edit Prototype... button on the upper left-hand corner of the screen, just above the actor's image.
After doing this, we will edit the main actor within the Library; so instead of having to program each...