Пример #1
0
 public void CheckGun()
 {
     if (hasgun == false)
     {
         if (Goodguy.IsTouching(pictureBoxGun))
         {
             hasgun = true;
             pictureBoxGun.Visible = false;
         }
     }
 }
Пример #2
0
 private void CheckDoors()
 {
     //if (pictureBoxPlayer.IsTouching(labelDeath))
     //{
     //    MainForm.NextForm = "GameOver";
     //    Close();
     //}
     if (Goodguy.IsTouching(pictureBoxCave))
     {
         MainForm.NextForm = "SecondForm";
         Close();
     }
 }
Пример #3
0
        private bool CanMove()
        {
            if (Goodguy.IsInsideOfForm() == false)
            {
                return(false);
            }

            foreach (var tree in trees)
            {
                if (Goodguy.IsTouching(tree) == true)
                {
                    return(false);
                }
            }

            return(true);
        }