Screen resolution default is native, and Screen.resolutions problems.

I’ve ran in to some odd issues with resolutions when I updated to the newest version of Unity.

In player settings, setting resolution “Default is Native Resolution”, the screen size always sets to 640x480. This isn’t just on my machine, this is on many machines.

I’ve noticed that when I check Screen.resolutions, it returns an array with a length of 1, and the only value is 640x480.

It seems like Unity is having some troubles getting resolutions from the system, does anyone know of any fixes to this? Or why this may be caused?

The editor only uses 640x480, since the game window isn’t a “real” resolution and can be any size. It works as expected in a build, where you have actual access to the system resolutions.

–Eric

Actually setting both “Default Is Full Screen” and “Default Is Native Resolution” have no effect after building the standalone. It’s broken.
Even though I checked those, when I open the build I see a different resolution than my native and the “Windowed” is checked.

How to fix it?

Once you’ve run the build, then it saves the resolution selections in the preferences. Even if you delete the app or rebuild it, the preferences won’t change. You can delete the preferences if you want it to “start clean”.

–Eric

I deleted the registry but the default resolution in the Build is still different than the Native. Well, maybe I didn’t delete the correct registry (the preferences are stored in the registry, right?).