Beispiel #1
0
    public override void OnReceiveIngredient(IPickable pickable)
    {
        if (currentKitchenItemHolding != null)
        {
            return;
        }

        if (!(pickable is ICortable))
        {
            return;
        }

        pickable.MoveTo(this);
        currentKitchenItemHolding = pickable;
    }
Beispiel #2
0
    public override void OnReceiveIngredient(IPickable pickable)
    {
        if (!(pickable is Ingredient))
        {
            return;
        }

        Ingredient ingredient = pickable as Ingredient;

        if (!_currentRecipe.Any())
        {
            CreateDish();
        }

        _currentPreparedDish.AddIngredient(ingredient.CurrentIngredientData);
        pickable.MoveTo(null);
        orderViewUI.SetIngredientImage(ingredient.CurrentIngredientData.grabbedImage);
        _currentRecipe.Add(ingredient.CurrentIngredientData);

        pickable.Delete();
    }
Beispiel #3
0
    public override void OnReceiveIngredient(IPickable pickable)
    {
        if (!(pickable is IEntregable))
        {
            return;
        }

        bool isGood = true;

        pickable.MoveTo(this);
        pickable.Delete();

        IEntregable           entregable        = pickable as IEntregable;
        List <IngredientData> auxIngredientList = entregable.GetIngredientsInOrder();

        if (!auxIngredientList.SequenceEqual(_currentRecipe.ingredients))
        {
            isGood = false;
        }

        CheckOrder(isGood);
    }
Beispiel #4
0
    public override void OnReceiveIngredient(IPickable pickable)
    {
        pickable.MoveTo(this);

        pickable.Delete();
    }