Posts

Showing posts from February, 2018

Week 3 Practical

Image
In my Week 3 practical class, I was asked to create three different scenes which reflected the addition of gravity, jumping, inertia and acceleration. Scene 1:  My first scene is a 2D race mini-game where the user (cube) races against two AI cubes. The AI cubes have random acceleration and max speeds, which remains constant throughout runtime. The player control can stop with inertia by releasing the movement key (KeyCode.D) or by pressing the space-bar. The script includes capping the Velocity and stopping the movement progressively. This scene demonstrates the concepts of Movement on a single axis, Velocity , Acceleration and Speed, and Inertia . Scene 2: My second scene is a mini-game where the user controls a spaceship (cube) which flies across the world. It uses a Debug.DrawLine to show the distance between the current position and the intended direction (calculated by Velocity * Time.deltaTime). This scene demonstrates the concepts of movement on multip

Week 2 Practical

During week 2, we learnt about coordinates in world/local forms, normalized vectors, displacement, velocity, drawing vectors, and targeting, following and chasing objects. This week, I was asked to produce a scene which allows the user to move a cube, with the enemy targeting the player at certain points. If the enemy was less than 5 units away from the player, it would start to follow it. After 3 seconds, it would chase and close in on the player. This uses Directional Vectors , Target mechanics , normalized  Vectors and distances. The below clips shows the evidence.