Im using this to set the GUI texture: GUI.DrawTexture (Rect (0,0, withTimer.width, withTimer.height), withTimer); How can I set the z index of it (as I have text that goes over the top) Cheers
The GUI class does not have a transform and does not occupy space in the 3D game space. All GUI calls are always rendered in front of everything else in the main game world. As far as drawing order of GUI elements, for a given OnGUI function execution, the layering will depend on the order you have them drawing in your code. If you are trying to control the order of GUI elements being drawn by different scripts, use this: http://unity3d.com/support/documentation/ScriptReference/GUI-depth.html Also, if you are just trying to use a texture for a window or button background, you probably want to define custom GUI styles using the image instead of drawing it separately. And the system will do a lot more for you.