Unity Tutorial 05

 

Image Source


In Unity tutorial 5, lesson 3.1 we start off by setting the background for our game, we then we set up a player character also adding a rigid body component and a box collider, we also create a playercontroller script. 

Before we start the game we make the player jump and then we make the player jump by pressing the spacebar. Once we can see that our player jumps as we press spacebar, we then tweak the the jump force and gravity. We then use an if-statement to make sure the player doesn't double-jump.

 Next we apply the MoveLeft script onto the background and create a spawn manager, we then write a function to spawn obstacles on a timer.

In lesson 3.2 we focus on making the background repeat itself to make it seem like our character is moving forward. In order to make it seem like the world is rushing by, we need to reset the background objects position so it fits perfectly together.

 By adding a box collider component to the background we fix the background repeat and it stops the transition from looking awkward. We then add a game over trigger when our character runs into one of the obstacles, we stop the moveleft script once the game is over. 

 Once the game is over we notice that the obstacles are still spawning so we add a condition to stop the obstacles spawning once the game is over.

In lesson 3.3, which is also last we add animations to our character to make it look more lifelike and realistic. At first we explore all the possible animations for our character and the new move onto giving our character animations such as running,jumping and even death. We also fix the speed of each animation to make it fit into the gameplay better. 

Comments

Popular posts from this blog

My Introduction

Game Design Document

Game Brainstorm