Exemplo n.º 1
0
 public void Clean_potato(Ice p)
 {
     if (p.Have_scin)
     {
         p.Have_scin = false;
     }
 }
Exemplo n.º 2
0
 public void WashPotato(Ice p)
 {
     if (State)
     {
         p.Dirty = 0;
     }
 }
Exemplo n.º 3
0
 private void button15_Click(object sender, EventArgs e)
 {
     potato = new Ice[3];
     for (int i = 0; i < potato.Length; i++)
     {
         potato[i] = new Ice();
     }
     carrot = new Chokolate[2];
     for (int i = 0; i < carrot.Length; i++)
     {
         carrot[i] = new Chokolate();
     }
     onion = new Icecream[2];
     for (int i = 0; i < onion.Length; i++)
     {
         onion[i] = new Icecream();
     }
     chicken = new Vanil();
     lapsha  = new Milk();
 }
Exemplo n.º 4
0
        private void button4_Click(object sender, EventArgs e)
        {
            if (!waterTap.State)
            {
                MessageBox.Show("Холодос закрыт, может откроем?", "Ошибка логики", MessageBoxButtons.OK, MessageBoxIcon.Error);
                return;
            }

            else
            {
                for (int i = 0; i < potato.Length; ++i)
                {
                    potato[i] = new Ice();
                }
                for (int i = 0; i < potato.Length; ++i)
                {
                    potato[i].Dirty = 0;
                }
            }


            MessageBox.Show("Молоко достали", "Кухня", MessageBoxButtons.OK, MessageBoxIcon.Information);
        }