- Home /
Problem is not reproducible or outdated
iPhone interface interaction.
When i load a new level on the iphone i can interact with the interface of the next level before it's even loaded.
It's doesn't wait for the scene to show before the commands take effect.
Can anyone help? Thank you
have you tried to remake the load function with a standard build on PC /$$anonymous$$AC platform - like for the webplayer to see if its an iOS problem or a problem with your code?
Answer by BerggreenDK · Feb 08, 2012 at 07:06 PM
Can you show a bit of the code loading your scene/levels?
if not, check this link:
http://unity3d.com/support/documentation/ScriptReference/MonoBehaviour.OnLevelWasLoaded.html
and
http://unity3d.com/support/documentation/ScriptReference/Application.LoadLevel.html
Answer by psycocrusher · Feb 08, 2012 at 09:30 PM
I'am using application.loadLevel when my conditions is met.
This is the command i use on my guiTexture:
function Update(){
for (var VarName : Touch in Input.touches) {
if(VarName.phase == TouchPhase.Ended && guiTexture.HitTest(VarName.position)){
gameObject.Find("Loading").guiTexture.enabled = true;
if(gameObject.Find("Loading").guiTexture.enabled == true){
Application.LoadLevel(6);
}
}
}
}
I tried a boolean and enable the command OnLevelWasLoaded and it didn't work either.
it's the same problem as this one: http://answers.unity3d.com/questions/151353/touch-is-remembered-through-loading-level.html#answer-215380
Follow this Question
Related Questions
touch to loadlevel 2 Answers
Fade to white after being killed - iPhone game 2 Answers
porting MouseDown to iPhoneInput.Touch and/or uniTUIO events 1 Answer
How do you get consistent gyroscope rotations on 2 axis? 0 Answers
How to make a loading screen? 2 Answers