- Home /
How to create a button on iPhone Unity?
I realise that this is a bit of a stupid question but i've been googling it for the past 20 mins and I still can't find the answer, I know how to do it on standard Unity, just not on the iPhone. I have a GUITexture on my iPhone app and I want to detect a touch of it. How do I do this?
This is a duplicate of http://answers.unity3d.com/questions/12853/extremely-basic-button-question
@OddProblem, you should re-check your other Question. @$$anonymous$$ike updated his Answer with the iPhone information, there was no need to ask again.
Answer by visu · Apr 01, 2011 at 08:11 AM
var style: GUIStyle;// add texture here.(Normal Style)
function OnGUI(){
if(GUI.Button(Rect(Size), style))
{
// Write Your code............
}
}
Your answer
![](https://koobas.hobune.stream/wayback/20220613062504im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
CharController on a rising bridge 1 Answer
Not expecting void Start 0 Answers
unity / kinect with infer.net problem 0 Answers
Lightmapping ignoring objects 1 Answer