GUI box

hey guys another quick question, i’ve noticed that when i create a script with the GUI fucntion and use X and y coords i’ve noticed that if you full screen then it wont be in the same position that it would if it were not full screen, what would be an easy fix to this? i’ve seen alot of scripts that use /2 which im guessing means half the game resoultion :stuck_out_tongue: cheers.

function OnGUI () {
if (loginIsUp) {
login = GUI.TextField (Rect (Xpos, Ypos, 200, 20), login, 25);
LogPass = GUI.PasswordField (Rect (Xpos1,Ypos1,200,20), LogPass,"*"[0], 25);

you can use Screen.width and Screen.height to place GUI elements. For example
Screen.width * 0.5
and accordingly
Screen.height * 0.5
would be the center of the screen

thanks man