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

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

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: