- Home /
 
 
               Question by 
               hatzalex · Oct 31, 2011 at 11:42 AM · 
                iphoneguitextscene-switchingiphonetouch  
              
 
              Unity iPhone scene transition on Tap of GUIText
Hallo every one,
I've been working with this for quite awhile now and I just can't get to make it work. What i'm trying to do is to load the main level from the main menu when I tap the GUIText for the iPhone.
 function Update () 
 
               { if(Input.touchCount == 1) { var currentTouch:Touch = Input.touches[0];
         if(currentTouch.phase == TouchPhase.Began && guiText.HitTest(currentTouch.position))
         {
                                         
             Application.LoadLevel(2);
         }
 }
 
               }
When i build and test it the touch doesn't work and i get no errors so I'm kinda lost here.
Am i coding it wrong, or isn't possible to accomplish this using guiText?
Thanks in advance.
               Comment
              
 
               
              Your answer
 
             Follow this Question
Related Questions
Touches don't respond correct 2 Answers
Alternative of touchesMoved in Unity3D 0 Answers
A node in a childnode? 1 Answer
Unity iPhone Textfield 0 Answers
All objects response to one touch 1 Answer