Esempio n. 1
0
 public void EndMarket()
 {
     MarketPanel.Close();
     MarketPanel    = null;
     AutoHideBubble = false;
     PositionItems();
 }
Esempio n. 2
0
        public void BeginMarket(TradeEnvoy Envoy, Faction PlayerFaction)
        {
            PlayerFaction.World.Tutorial("market_screen");
            MarketPanel = GuiRoot.ConstructWidget(new Gui.Widgets.MarketPanel
            {
                Rect   = GuiRoot.RenderData.VirtualScreen,
                Player = new Trade.PlayerTradeEntity(PlayerFaction),
            }) as Gui.Widgets.MarketPanel;

            MarketPanel.Layout();

            GuiRoot.ShowDialog(MarketPanel);
            GuiRoot.RootItem.SendToBack(MarketPanel);

            AutoHideBubble = true;

            SpeakerBorder.Rect = new Rectangle(16, GuiRoot.RenderData.VirtualScreen.Height - (256 - 16), 256 - 32, 256 - 32);
            SpeakerRectangle.EntireMeshAsPart()
            .ResetQuad()
            .Scale(256, 256).Translate(0, GuiRoot.RenderData.VirtualScreen.Height - 256);
            _Output.Rect = new Rectangle(256, GuiRoot.RenderData.VirtualScreen.Height - 260, global::System.Math.Min(GuiRoot.RenderData.VirtualScreen.Width - 256, 550), 260);

            SpeakerBorder.Invalidate();
            _Output.Invalidate();
            GuiRoot.RootItem.Invalidate();
        }