Skip to content

Files

Latest commit

 

History

History

How-Math-is-Used-in-Video-Games

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

🎓 🎮 How Math is Used in Video Games: Video Guide on Math in Video Games

🔗 Online course on BitDegree

Mathematics in Games

  1. 2D and 3D co-ordinate system
  2. Vector2D and Vector3D (direction and velocity)

ℹ️ Mathematical Formula

Distance between 2 points

All about Vectors

  • d = √[(y2 – y1)² + (x1 – x2)²]
  • d = √[(y1 – y2)² + (x1 – x2)² + (z1 - z2)²]

Velocity

  • v = d / t

Projectile motion

  • position y = Amplitude * cos (initial angle)

Pathfinding Algorithms

Unity implements the Nav Mesh Agent

  • A* search algorithm
  • Dijkstra's algorithm, an uninformed, less powerful special case of the A* search algorithm
  • D* family of incremental heuristic search algorithms
  • Any-angle path planning algorithms

Collision

Rectangle (2D) or box shape (3D) also polygonal, mesh and triangle.

📝 Version

This project was created with Unity 2018.4.32f1

📃 License

The source code I created is free -- see the LICENSE file for details.
Please also have a look at the Asset Store Terms of Service and EULA for use of the game assets.