- Home /
Duplicate Question
show texture on key down
i'm trying to make a note that the player can pick up and read, i what to make it so when the player goes near a gameobject and press "E" a texture apears on the screen and when the player press "E" another time it will desapear some help please :) sorry for my spelling
Input.GetButtonUp, GUITexture on/off; please search UA for many similar questions/answers, tuts, vids, code snippets and other resources; questions like this have been asked many times.
@smiley - moderators earn the right to close questions by participating on the list and answering hundreds of questions. I would have closed your question as well. You question gives no indication that you tried in any way to solve your own problem. And you are specifying a recipe for someone to write some code for you. Unity Answers addresses single specific questions to help you write your own code. Do some research. Try to script it yourself, if you get stuck, post back with your script attempt.
this is what i have so far what i whant to do is enable the GUITexture when the player is in the trigger and pressing "E" and when the player press "E" again the GUITexture desables
this is the trigger script
pragma strict
ar page : GUITexture;
function Start () { page.enabled = false
}
function Update () { OnTriggerStay(Collision); Input.Get$$anonymous$$eyDown($$anonymous$$eyCode.E); } if(Input.Get$$anonymous$$eyDown($$anonymous$$eyCode.E) = true{ page.enabled = true } function Update () { if(Input.Get$$anonymous$$eyDown($$anonymous$$eyCode.E) = true{ page.enabled = false } }
Follow this Question
Related Questions
particle system that kicks up dust behind a tire 3 Answers
Assigning UV Map to model at runtime 0 Answers
i need detailed instructions... cue texture 1 Answer
Showing a picture on collision errors 1 Answer
Show GUI texture then not 0 Answers