Hi everyone,
I’m currently stuck with the problem of android resolutions and I just wanted get all resolutions possible with the standard unity script:
function Start()
{
var resolutions : Resolution[] = Screen.resolutions;
// Print the resolutions
for (var res in resolutions) {
print(res.width + "x" + res.height);
}
// Switch to the lowest supported fullscreen resolution
Screen.SetResolution (resolutions[0].width, resolutions[0].height, true);
};
but when trying this, I’ll get some errors:
Assets/Resolution.js(5,49): BCE0022: Cannot convert 'UnityEngine.Resolution[]' to 'Resolution[]'.
Assets/Resolution.js(8,23): BCE0019: 'width' is not a member of 'Resolution'.
Does anyone know, why this is not working?