public bool checkCollision(GameObject object2) { float distance = (float)(Math.Sqrt(Math.Pow((this.x - object2.x), 2) + Math.Pow(this.y - object2.y, 2))); if (distance < this.radius + object2.radius) return true; return false; }