Exemplo n.º 1
0
    public VendingMachine(int startingCost, VendingType vendingType, Rectangle displayRectangle, Texture2D Texture, float depth)
    {
        sourceRect      = Texture.Bounds;
        displayLocation = displayRectangle.Location.ToVector2();
        collider        = displayRectangle;
        texture         = Texture;
        drawDepth       = depth;

        type = vendingType;
    }
Exemplo n.º 2
0
    public Transform VendingPosition(VendingType vendingType)
    {
        _vendingTransform = null;

        switch (vendingType)
        {
        case VendingType.Coffee:
            _vendingTransform = _coffeeVendingPoint;
            break;

        case VendingType.Milk:
            _vendingTransform = _milkVendingPoint;
            break;

        case VendingType.Fish:
            _vendingTransform = _fishVendingPoint;
            break;
        }

        return(_vendingTransform);
    }