Thursday, 10 November 2016

Our simple Game

Previous: things to put in mind

Our simple Game.
The game in this tutorial is basic game to demonstrate how to develop games in unity. The game is a 2D.
Please follow steps described in the tutorial: Basics you need to know here. Name the project as "Catch A box." 
Make sure you are under scene view. We now add a box. It is a 3D object added to 2D view.

We can add it in two ways
  1. From GameObject menu -> 3D object -> cube.
  2. From hierarchy, create -> 3D object -> cube.
Make sure you can see the rectangular box in both scene view and game view. The position does not matter at this time. We will work to position it to the right place as we build our game.

In the inspector, the setting for our box are now visible. Transform settings helps in positioning, scaling and rotating the box. collides will be used to test if the box comes into contact with any other game object.

Select the box if not selected in the hierarchy menu and in the inspector menu, change the name from cube to box as show below. Change its y position to 4.

We also need to add floor where all boxes will fall to. Add another box, call it catch up and adjust y position to -4.5 and scale it to 3 along x.

click on game view to see how the two boxes look like. We have now our bases for the game. The box at the top represent the box falling down while the one at the bottom represent the box capturing the falling boxes.

The box at the top will use gravity to fall.

In the next lesson, we learn gravity and collision. We will let the box fall and capture it with the box at the bottom.

Next: Adding movement

No comments:

Post a Comment