Working with buttons

Now that we have the text displaying correctly, let's add the ability to move from the main menu into the game properly. However, unlike our title, for things that we want our players to touch, it's a good idea to make these buttons the same size in each device, as our fingers are the same size, no matter what device we are using. To show a possible solution for this, we will create a new Canvas using a different scaling technique.

  1. We will first rename our current Canvas object to Canvas - Scale Screen. This way, we can easily tell whether we are using the correct canvas for this or not.
  1. Now that we have that one ready, we can create our new one. Go to the top menu bar and then select GameObject | UI | Canvas. Rename ...

Get Unity 2017 Mobile Game Development now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.