I want to create a GUI with GUIText and GUITexture. I created a simple pad in photoshop and made it to a GUITexture. Now I want to chane its width by code, it has to get the width of the screen. I also want to place GUIText always 5 Pixel left from the roght upper corner.
How could I achieve that? THX!
asked May 11 '10 at 01:39 PM
You could also just create buttons and windows to your liking with each texture and then independently render them on GUI. You actually get a much better look to your GUI if you do things this way. You don't need Skins.
First in your scene create an empty game object, then attach this script to it..
var icon: Texture2D; //this is your texture.
} //this creates a variable space in the inspector where you drag and drop your texture.
Attach this script to your empty object, and you are done without using skins.
answered Jun 09 '10 at 10:16 PM