Introduction - If you have any usage issues, please Google them yourself
Basic concept description
The code above is useful for checking conflicts between units (such as friendly planes and enemy missiles) when making 2D-based games.
The basic principle of this code is to use the center distance and the sum of the radii of two circles. The distance between the centers of the two circles can be found by the Pythagorean theorem. If the sum of the radii of the two circles is greater than the center distance, the object is considered as a collision (If you do not know, you can see the illustrations)