Set resolution ignored when game ran with "dotnet run"

I’m changing the Graphics.PreferredBackBuffer Width and Height to set the resolution, which worked fine when I was using Rider, but I can’t get it to work when I run my project using the dotnet cli tool. Printing the BackBuffer’s resolution does show the correct resolution.

Has anyone experienced this?

There is a bug with setting the side in constructor, instead you can set it in init or any time later on, just call the apply.

1 Like

This worked, many thanks

I noticed this too when I just upgraded to VS 2019 & MonoGame 3.8
Seemed like the backbuffer actually has the right resolution and the window stays the same size.
Ya, works fine to apply changes in init. Thanks for the tip. :slight_smile: