- Home /
Show/hide GUI Texture
Hi, I've got a problem with showing GUI textures. In my game's main menu, when I click the How to play button, I want it to show a GUI texture which tells how to play the game. I'm not a programmer so making scripts is kind of a new thing to me. Anyway, here's my script:
var isHowtoButton = false; var GUITexture = false;
function OnMouseDown() { renderer.material.color = Color.green; if ( isHowtoButton ) { guiTexture.enabled = true; } }
Answer by getyour411 · Jan 12, 2014 at 08:15 PM
Check out the Unity doc on GUI.Button (and using it wrapped in an IF to do stuff on mousepush) and OnGUI
Your answer
Follow this Question
Related Questions
Hide/show GUI Buion 1 Answer
I have doubt please help me 2 Answers
Scripting a GUI button to move object smoothly 1 Answer
On Button press Move Value toward 2 Answers
Unity 4.6 UI change button color when pressed. -Javascript 1 Answer