Пример #1
0
        public void Cuisiner(Recette recette)
        {
            Objets objets = new Objets();

            Thread.Sleep(recette.tmpsCuisson + recette.tmpsPreparation);

            foreach (Ingredient ingredient in recette.listIngredients)
            {
                ingredient.quantiteIngredient--;
            }
        }
Пример #2
0
        public void Instanciation()
        {
            Ingredient pain = new Ingredient("pain", 99);

            Ingredient pates       = new Ingredient("pates", 99);
            Ingredient riz         = new Ingredient("riz", 99);
            Ingredient poulet      = new Ingredient("poulet", 99);
            Ingredient boeuf       = new Ingredient("boeuf", 99);
            Ingredient saucetomate = new Ingredient("saucetomate", 99);
            Ingredient creme       = new Ingredient("creme", 99);
            Ingredient chocolat    = new Ingredient("chocolat", 99);
            Ingredient vanille     = new Ingredient("vanille", 99);
            Ingredient oeuf        = new Ingredient("oeuf", 99);
            Ingredient farine      = new Ingredient("farine", 99);
            Ingredient tomate      = new Ingredient("tomate", 99);
            Ingredient mozzarella  = new Ingredient("mozzarella", 99);

            Recette bolognaise = new Recette("spaghetti bolognaise", new List <Ingredient> {
                pates, boeuf, saucetomate
            }, 10, "PLAT");
            Recette rizpoulet = new Recette("riz au poulet", new List <Ingredient> {
                riz, poulet, creme
            }, 10, "PLAT");
            Recette gateauchocolat = new Recette("gateau au chocolat", new List <Ingredient> {
                chocolat, oeuf, farine
            }, 10, "DESSERT");
            Recette gateauvanille = new Recette("gateau à la vanille", new List <Ingredient> {
                vanille, oeuf, farine
            }, 10, "DESSERT");
            Recette oeufsauplat = new Recette("oeufs au plat", new List <Ingredient> {
                oeuf
            }, 10, "ENTREE");
            Recette tomatemozza = new Recette("tomates mozzarella", new List <Ingredient> {
                tomate, mozzarella
            }, 5, "ENTREE");

            Recette erreur = new Recette("erreur", new List <Ingredient> {
            }, 0, "ENTREE");

            recettes.Add(bolognaise);
            recettes.Add(rizpoulet);
            recettes.Add(gateauchocolat);
            recettes.Add(gateauvanille);
            recettes.Add(oeufsauplat);
            recettes.Add(tomatemozza);

            recettes.Add(erreur);

            ingredients.Add(pain);

            ingredients.Add(pates);
            ingredients.Add(riz);
            ingredients.Add(poulet);
            ingredients.Add(boeuf);
            ingredients.Add(saucetomate);
            ingredients.Add(creme);
            ingredients.Add(chocolat);
            ingredients.Add(vanille);
            ingredients.Add(oeuf);
            ingredients.Add(farine);
            ingredients.Add(tomate);
            ingredients.Add(mozzarella);
        }
Пример #3
0
        public void Preparation()
        {
            //Ingredients
            Ingredient lait = new Ingredient("lait", 150);

            ingredients.Add(lait);

            Ingredient saucetomate = new Ingredient("saucetomate", 150);

            ingredients.Add(saucetomate);

            Ingredient creme = new Ingredient("creme", 150);

            ingredients.Add(creme);

            Ingredient chocolat = new Ingredient("chocolat", 150);

            ingredients.Add(chocolat);

            Ingredient gruyere = new Ingredient("gruyere", 150);

            ingredients.Add(gruyere);

            Ingredient vanille = new Ingredient("vanille", 150);

            ingredients.Add(vanille);

            Ingredient oeuf = new Ingredient("oeuf", 150);

            ingredients.Add(oeuf);

            Ingredient chou = new Ingredient("chou pommé blanc", 150);

            ingredients.Add(chou);

            Ingredient carotte = new Ingredient("carotte", 150);

            ingredients.Add(carotte);

            Ingredient pates = new Ingredient("pates", 150);

            ingredients.Add(pates);

            Ingredient riz = new Ingredient("riz", 150);

            ingredients.Add(riz);;

            Ingredient poulet = new Ingredient("poulet", 150);

            ingredients.Add(poulet);

            Ingredient boeuf = new Ingredient("boeuf", 150);

            ingredients.Add(boeuf);

            Ingredient poivre = new Ingredient("poivre", 150);

            ingredients.Add(poivre);

            Ingredient cremefraiche = new Ingredient("creme fraiche", 150);

            ingredients.Add(cremefraiche);

            Ingredient biscuit = new Ingredient("biscuit", 150);

            ingredients.Add(biscuit);

            Ingredient cafe = new Ingredient("café", 150);

            ingredients.Add(cafe);

            Ingredient farine = new Ingredient("farine", 150);

            ingredients.Add(farine);

            Ingredient tomate = new Ingredient("tomate", 150);

            ingredients.Add(tomate);

            Ingredient cacao = new Ingredient("cacao", 150);

            ingredients.Add(cacao);

            Ingredient mozzarella = new Ingredient("mozzarella", 150);

            ingredients.Add(mozzarella);

            Ingredient poisson = new Ingredient("poisson", 150);

            ingredients.Add(poisson);

            Ingredient pommedeterre = new Ingredient("pomme de terre", 150);

            ingredients.Add(pommedeterre);

            Ingredient chapelure = new Ingredient("chapelure", 150);

            ingredients.Add(chapelure);

            Ingredient pateBrise = new Ingredient("pâte brisé", 150);

            ingredients.Add(pateBrise);

            Ingredient beurre = new Ingredient("beurre", 150);

            ingredients.Add(beurre);

            Ingredient pomme = new Ingredient("pomme", 150);

            ingredients.Add(pomme);

            Ingredient sucre = new Ingredient("sucre en poudre", 150);

            ingredients.Add(sucre);


            //Recettes
            Recette nuggetsfrite = new Recette("nuggets et frites", new List <Ingredient> {
                pommedeterre, oeuf, poulet, chapelure, farine
            }, 4000, 1000, "PLAT");

            recettes.Add(nuggetsfrite);

            Recette fishandchips = new Recette("fish and chips", new List <Ingredient> {
                poisson, pommedeterre
            }, 3000, 2000, "PLAT");

            recettes.Add(fishandchips);

            Recette bolognaise = new Recette("spaghetti bolognaise", new List <Ingredient> {
                pates, boeuf, saucetomate
            }, 3000, 2000, "PLAT");

            recettes.Add(bolognaise);

            Recette crepechocolat = new Recette("crêpe au chocolat", new List <Ingredient> {
                sucre, farine, oeuf, cacao, lait
            }, 1000, 2000, "DESSERT");

            recettes.Add(crepechocolat);

            Recette glacechocolat = new Recette("glace au chocolat", new List <Ingredient> {
                chocolat, sucre, cacao, cremefraiche, lait
            }, 1000, 2000, "DESSERT");

            recettes.Add(glacechocolat);

            Recette tiramisu = new Recette("tiramisu", new List <Ingredient> {
                cafe, cacao, sucre, biscuit
            }, 1000, 2000, "DESSERT");

            recettes.Add(tiramisu);

            Recette gateauvanille = new Recette("gateau à la vanille", new List <Ingredient> {
                vanille, oeuf, farine
            }, 1000, 2000, "DESSERT");

            recettes.Add(gateauvanille);

            Recette tartepomme = new Recette("tarte aux pommes", new List <Ingredient> {
                pateBrise, oeuf, pomme, sucre
            }, 1000, 2000, "DESSERT");

            recettes.Add(tartepomme);

            Recette oeufscoque = new Recette("oeufs à la coque", new List <Ingredient> {
                oeuf, beurre
            }, 500, 1500, "ENTREE");

            recettes.Add(oeufscoque);

            Recette rizpoulet = new Recette("riz au poulet", new List <Ingredient> {
                riz, poulet, creme
            }, 3000, 2000, "PLAT");

            recettes.Add(rizpoulet);

            Recette oeufcocotte = new Recette("oeuf cocotte", new List <Ingredient> {
                oeuf, gruyere, cremefraiche, poivre
            }, 500, 1500, "ENTREE");

            recettes.Add(oeufcocotte);

            Recette tomatemozza = new Recette("tomates mozzarella", new List <Ingredient> {
                tomate, mozzarella
            }, 1500, 500, "ENTREE");

            recettes.Add(tomatemozza);

            Recette pommeterresurprise = new Recette("pomme de terre surprise", new List <Ingredient> {
                pommedeterre, oeuf, poivre, carotte, chou
            }, 500, 1500, "ENTREE");

            recettes.Add(pommeterresurprise);
        }