示例#1
0
        protected override void OnEnter()
        {
            this.Game.IsMouseVisible = true;
            GUISceneManager.SwitchScene(this.scene);

            this.tempResolution = WindowSettings.WindowResolution;
            this.currentIndex   = 0;
            foreach (Resolution r in this.resolutions.Keys)
            {
                if (this.resolutions[r].X <= this.tempResolution.X && this.resolutions[r].Y <= this.tempResolution.Y)
                {
                    this.currentIndex = (int)r;
                }
            }

            // bug: when window is not size from list, applying to this size sets to selected size from list, not actual size
            this.combobox.Selector.TextBlock.Text = this.ToResolutionString(this.tempResolution);
            this.borderlessCheck.IsChecked        = UserConfig.Instance.Borderless;

            this.netServerTextbox.SetEnabled(false);
            this.netPortTextbox.SetEnabled(false);
        }
示例#2
0
 protected override void OnEnter()
 {
     this.Game.IsMouseVisible = true;
     GUISceneManager.SwitchScene(this.screen);
 }
示例#3
0
 protected override void OnEnter()
 {
     this.Game.IsMouseVisible = true;
     GUISceneManager.SwitchScene(this.scene);
     this.connectionInfo.SendReliablePacket(new RequestLobbyInfoPacket());
 }
示例#4
0
        //private enum MainMenuItems
        //{
        //    Singleplayer, Multiplayer, Settings, Exit,
        //}

        protected override void OnEnter()
        {
            //Microsoft.Xna.Framework.Input.Mouse.SetCursor(Microsoft.Xna.Framework.Input.MouseCursor.FromTexture2D(new Texture2D(game.GraphicsDevice,1,1),1,1));
            this.Game.IsMouseVisible = true;
            GUISceneManager.SwitchScene(this.scene);
        }