예제 #1
0
파일: GameState.cs 프로젝트: Groompel/PP2
 public void CheckCollision()
 {
     if (worm.CheckIntersection(food.body))
     {
         worm.Eat(food.body);
         food.Generate();
     }
     if (worm.CheckIntersection(wall.body))
     {
         //GameOver = true;
     }
 }
예제 #2
0
 void CheckColision()
 {
     if (worm.CheckIntersection(food.body) == true)
     {
         worm.Eat(food.body);
         food.Generate();
     }
 }
예제 #3
0
 public void CheckCollision()
 {
     if (worm.CheckIntersection(food.body[0]))
     {
         worm.Eat(food.body[0]);
         food.Generate();
     }
 }