Exemple #1
0
        public Player(Grid grd, Grid grd_next, Label _lbl_name, Label _lbl_lvl, Label _lbl_scores, Label _lbl_lines)
        {
            lvl_now = lvl_max;
            lbl_name = _lbl_name;
            lbl_lvl = _lbl_lvl;
            lbl_scores = _lbl_scores;
            lbl_lines = _lbl_lines;
            lbl_name.Content = "Name: " + name;
            lbl_lvl.Content = "Lvl: " + lvl_max;
            lbl_scores.Content = "Score: " + Convert.ToString(scores);
            lbl_lines.Content = "Line: " + Convert.ToString(lines);

            glass_next = new Glass(grd_next, grd_next.RowDefinitions.Count, grd_next.ColumnDefinitions.Count);
            glass_next.BackgroundOfGlass = Brushes.Gray;
            glass_next.CollorOfGlass = Brushes.Gray;
            figure_next = new Figura(glass_next);
            figure_next.CollorOfFigura = Brushes.BurlyWood;

            glass = new Glass(grd, grd.RowDefinitions.Count, grd.ColumnDefinitions.Count);
            figura = new Figura(glass);
        }
Exemple #2
0
 public Figura(Glass _glass)
 {
     glass = _glass;
     figure_now = rnd.Next(0, 7);
     figure_next = rnd.Next(0, 7);
 }