- Home /
Help creating button list of available resolutions
OKay, I have a problem with this for :C . I'm trying to make few buttons with the resolution that the user can select, but I dont know why it dont works.
PLIS HELP!
for (int i = 1; i < Screen.resolutions.Length;i++ )
{
if(GUI.Button( new Rect(400, 200 + (50 * i), Screen.width / 8, Screen.height / 10), Screen.resolutions[i].width + "X" + Screen.resolutions[i].height))
{
Screen.SetResolution(Screen.resolutions[x].width,Screen.resolutions[x].height,true);
}
}
Comment
Your answer
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Working With GUI 1 Answer
UnityEngine.Input.GetMouseButton(1)) issue 1 Answer
How To Make GUI Buttons Load/Quit 1 Answer
GuiTexture Width Change 1 Answer