Creating our player
Having the basis of our world is great, but if we don't have a player, it doesn't matter how nice the level looks. In this section, we will create the actual player that will walk around and move in the world:
Let's first create a capsule by selecting GameObject | Create Other | Capsule. Have a look at the following screenshot:
Tip
If you are using Unity 4.6 or above, use the GameObject | 3D Object | Capsule
Right now, the capsule is too big to fit in our world because it is larger than our blocks. To easily fix this, we will set Scale of our capsule to (
.4
,.4
,.4
). Also, set Position to (1
,2
,0
).Now, we want our player to use gravity and forces, so we will need to add a rigid body component by going to Component | Physics | Rigid Body.
Note
The 2D and 3D Physics systems are not interchangeable. You'll need to choose one or the other when working on a project. We're using 3D right now, so you can have a good idea of what to look out for, and the differences between 2D and...