예제 #1
0
파일: Figura.cs 프로젝트: ehaj/rep1
 public Figura(Pozycja pozycja, string kolor)
 {
     this.pozycja = pozycja;
     this.kolor   = kolor;
 }
예제 #2
0
파일: Figura.cs 프로젝트: ehaj/rep1
        protected bool CzyPoziomo(Pozycja nowaPozycja)
        {
            return(Pozycja.X == nowaPozycja.X);

            PrzesunietoFigure;
        }
예제 #3
0
파일: Figura.cs 프로젝트: ehaj/rep1
        protected bool CzySkos(Pozycja nowaPozycja)
        {
            return(Math.Abs(Pozycja.Y - nowaPozycja.Y) == Math.Abs(Pozycja.X - nowaPozycja.X));

            PrzesunietoFigure;
        }
예제 #4
0
파일: Figura.cs 프로젝트: ehaj/rep1
        protected bool CzyPionowo(Pozycja nowaPozycja)
        {
            return(Pozycja.Y == nowaPozycja.Y);

            PrzesunietoFigure;
        }