Demonstrations


Vectors
Vectors is used to define a magnitude along with the direction. This is used in games to define a position, direction object is heading and the speed of the object along with distance of two objects.
​
Here, the resources are downloaded from the website given in the book, but instead of ducks, two different vehicles imported from Devassets.com.Aa script is written and attached to the Front vehicle. Front vehicle is then targeted to the second vehicle. Now when the game is loaded, the front vehicle moves towards second vehicle diagonally. Video of a game play, and two screen shots are provided as a part of the demonstration.
Bibiliography
Technologies, U., 2021. Unity - Manual: Important Classes - Vectors. [online] Docs.unity3d.com. Available at: <https://docs.unity3d.com/Manual/VectorCookbook.html#:~:text=Vectors%20can%20be%20expressed%20in%20multiple%20dimensions%2C%20and,all%20three%20types%20of%20Vector%20unless%20otherwise%20specified.> [Accessed 19 February 2021].
​
This reference is selected because the explanation on vector is very well done and also here mathematically the syntax and concept is given with every possibility with the vectors like direction, cross product result, Distance and so on.
​
Technologies, U., 2021. Unity - Scripting API: Vector2. [online] Docs.unity3d.com. Available at: <https://docs.unity3d.com/ScriptReference/Vector2.html> [Accessed 19 February 2021].
​
This reference is selected as it is important to learn vectors for 2D rather than 3D first. It has provided the static properties of 2D vectors, properties, constructors, methods, operators and so on. This is more useful in 2D gaming and scripting.
​
YouTube.com. 2021. C# Vector Maths in Unity! - Beginner Scripting Tutorial. [online] Available at: <https://www.youtube.com/watch?v=e3z91RqZPAk> [Accessed 19 February 2021].
​
This is a youtube video from Unity explaining the Vectors concept from 2D to 3D and all of the contents that they have in their official website and is beginner friendly.