Exemplo n.º 1
0
        private void onGraphicsDriverChanged(object sender, EventArgs e)
        {
            _restartNotice           = GuiMaster.ShowMessageBox(_content, "Changing renderers on-the-fly isn't supported (yet). You'll have to restart the game before settings take effect.", MsgBoxType.OK);
            _restartNotice.OnResult += new EventHandler <MsgBoxResultEventArgs>(onRestartNoticeResult);

            Settings.Renderer = _3dDriverDropdown.Items[_3dDriverDropdown.SelectedIndex].Key;
            Settings.Save();
        }
Exemplo n.º 2
0
        private void onGraphicsResChanged(object sender, EventArgs e)
        {
            _restartNotice           = GuiMaster.ShowMessageBox(_content, "Changing resolution on-the-fly isn't supported (yet). You'll have to restart the game before settings take effect.", MsgBoxType.OK);
            _restartNotice.OnResult += new EventHandler <MsgBoxResultEventArgs>(onRestartNoticeResult);

            string res = _resolutionDropdown.Items[_resolutionDropdown.SelectedIndex].Key;
            float  w, h;

            if (tryParse2f(res, out w, out h))
            {
                Settings.ScreenWidth  = (int)w;
                Settings.ScreenHeight = (int)h;
                Settings.Save();
            }
        }