Example #1
0
        void CheckSelfCollision()
        {
            if (worm.body.Count > 1 && worm.CheckIntersection2() == true)
            {
                worm.Clear();
                food.Clear();
                wall.Clear();
                Console.Clear();

                Console.WriteLine("Game over");
                Environment.Exit(0);
            }
        }