Exemple #1
0
        public void adjustSettingsOnStartup(GraphicsDeviceManager graphics)
        {
            GraphicsSettings.currentResolution = settings.settings["Resolution"];

            Game1.windowH = graphics.PreferredBackBufferHeight = (int)GraphicsSettings.resolutions[GraphicsSettings.currentResolution].Y;
            Game1.windowW = graphics.PreferredBackBufferWidth = (int)GraphicsSettings.resolutions[GraphicsSettings.currentResolution].X;

            Properties.globalScale = GraphicsSettings.trueGameScale(GraphicsSettings.resolutions[GraphicsSettings.currentResolution]);
            loadFullScreen(graphics);

            GraphicsSettings.correctResolutionForMonitor();
            graphics.HardwareModeSwitch = false;
            graphics.ApplyChanges();
        }
Exemple #2
0
 private void updateAllResolutionValues(GraphicsDeviceManager graphics)
 {
     /*if(!graphics.IsFullScreen)
      * {
      *  GraphicsSettings.currentResolution = GraphicsSettings.highestRes;
      * }
      * else
      * {
      *  GraphicsSettings.currentResolution = settings["Resolution"];
      * }*/
     //Properties.globalScale = GraphicsSettings.trueGameScale(GraphicsSettings.resolutions[GraphicsSettings.currentResolution]);
     //GraphicsSettings.correctResolutionForMonitor();
     graphics.PreferredBackBufferHeight = (int)GraphicsSettings.resolutions[GraphicsSettings.currentResolution].Y;
     graphics.PreferredBackBufferWidth  = (int)GraphicsSettings.resolutions[GraphicsSettings.currentResolution].X;
     Properties.globalScale             = GraphicsSettings.trueGameScale(GraphicsSettings.resolutions[GraphicsSettings.currentResolution]);
     setButtonPositions();
 }