1. Wulf

    Wulf Community Admin

    What exactly are you using? Pretty sure that's not really a new message.
     
  2. well something like that just don't work
    rawImage.Sprite = "assets/content/textures/generic/fulltransparent.tga";

    It seem we just can't click button

    Code:
            private static CuiElementContainer CreateShopOverlay(string shopname)
            {
                return new CuiElementContainer
                {
                    {
                        new CuiPanel
                        {
                            Image = {Color = "0.1 0.1 0.1 0.8"},
                            RectTransform = {AnchorMin = "0 0", AnchorMax = "1 1"},
                            CursorEnabled = true
                        },
                        new CuiElement().Parent,
                        ShopOverlayName
                    },
                    {
                        new CuiLabel
                        {
                            Text = {Text = shopname, FontSize = 30, Align = TextAnchor.MiddleCenter},
                            RectTransform = {AnchorMin = "0.3 0.8", AnchorMax = "0.7 0.9"}
                        },
                        ShopOverlayName
                    },
                    {
                        new CuiLabel
                        {
                            Text = {Text = "Item", FontSize = 20, Align = TextAnchor.MiddleLeft},
                            RectTransform = {AnchorMin = "0.2 0.6", AnchorMax = "0.4 0.65"}
                        },
                        ShopOverlayName
                    },
                    {
                        new CuiLabel
                        {
                            Text = {Text = "Buy", FontSize = 20, Align = TextAnchor.MiddleLeft},
                            RectTransform = {AnchorMin = "0.55 0.6", AnchorMax = "0.7 0.65"}
                        },
                        ShopOverlayName
                    },
                    {
                        new CuiLabel
                        {
                            Text = {Text = "Sell", FontSize = 20, Align = TextAnchor.MiddleLeft},
                            RectTransform = {AnchorMin = "0.75 0.6", AnchorMax = "0.9 0.65"}
                        },
                        ShopOverlayName
                    },
                    {
                        new CuiButton
                        {
                            Button = {Close = ShopOverlayName, Color = "0.5 0.5 0.5 0.2"},
                            RectTransform = {AnchorMin = "0.5 0.15", AnchorMax = "0.7 0.2"},
                            Text = {Text = "Close", FontSize = 20, Align = TextAnchor.MiddleCenter}
                        },
                        ShopOverlayName
                    }
                };
            }
    
    [DOUBLEPOST=1468533073][/DOUBLEPOST]#close nothing to do with transparency, it seem to be a but with button itself
     
    Last edited by a moderator: Jul 14, 2016