Exemplo n.º 1
0
        bool JeCestaVPravo()
        {
            AngryBird.Otoc(Do.Prava);
            var jeTamCesta = MuzeVpred();

            AngryBird.Otoc(Do.Leva);
            return(jeTamCesta);
        }
Exemplo n.º 2
0
 public void PoSpusteni()
 {
     while (HraciPlocha.NaPolickuPod(AngryBird) != TypPolicka.Prase)
     {
         if (MuzeVpred())
         {
             AngryBird.PosunoutVpred();
         }
         else
         {
             if (JeCestaVPravo())
             {
                 AngryBird.Otoc(Do.Prava);
             }
             else
             {
                 AngryBird.Otoc(Do.Leva);
             }
         }
     }
 }