The cosine rule:

Here is my current to do list:

  1. Add polish to game
  2. MURDER MY IDE UNTIL IT ACCEPTS MY CODE BASED ON THAT DARN COSINE RULE!!!
  3. …profit!
Anyway, if any of you want to hold grudges against mathematical formulae, might I recommend the cosine rule?

a^2 = b^2 + c^2 - 2 x b x c x cosA