skip to content
Scalable Hacker Blog

Search

Collision Detection (Practice 1)

Less than one minute read Updated:
Assignment 1

The concept of distace between 2 objexts

This is part of Math for Game Devs by Freya Holmér

Interactive Demo

Coverted to Three.js & R3F

  • Create a component you can put on objects, to detect whether or not another transform is inside of its radius
  • Draw debug gizmos to indicate inside/outside status
  • Make the radius configurable
  • Do not use colliders - this is a math exercise using vectors!

Code

GitHub