- Home /
When I show a picture on the GUI there is a square behind the picture
I have added a bar to my game, but behind it there is an strange square, here you have a pic: http://imageshack.us/photo/my-images/263/sinttulord.png/ What I'm doing wrong?
Here you have the script:
GUI.BeginGroup (new Rect (pos.x, pos.y, size.x, size.y));
GUI.Box (Rect (0,0, size.x, size.y),progressBarEmpty);
GUI.EndGroup ();
Hope you could help me, lot of thanks
That imageshack.us link seems to throw a lot of pop-ups including ones that offer to do virus scans on my $$anonymous$$ac. Think perhaps imageshack.us might have problems with malware today.
Answer by iggy · May 28, 2011 at 07:11 PM
That is what GUI.Box does.
Use Label (it will show texture only):
GUI.Label (Rect (0,0, size.x, size.y),progressBarEmpty);
source: http://unity3d.com/support/documentation/ScriptReference/GUI.Label.html
Your answer
Follow this Question
Related Questions
GUI box problem? 0 Answers
Change colour of GUI box, keep round corners. 0 Answers
How to display a rectangle around a player? 1 Answer
How To Get Current Mouse Position and have a GUI Box on right clicked 2 Answers
Custom GUI.Box function dilemma 1 Answer