linking levels?

how do I link levels together? Say I want, when the character “falls off the edge” and falls for infinity, for him to hit a terrain that will load him to the next level, how can this be done? basicly I want a continuous loop of 2 levels I have created. when one falls from the edge of one, and hits the “under terrain”, it will load the character to my next created level. this level does the same as the first, only loading the character to the original level…a purgatory of sorts (Don’t ask, it’s for an art installation). Can anyone help me with this. I have taught myself Unity and know the basics, but know nothing of scripts, and can barely navigate the inner workings of the software. can someone baby step my way through this issue?
PLEASE!!!

Have a look at OnTriggerEnter in the unity documentation at http://unity3d.com/support/documentation/ScriptReference/Collider.html , as I expect you could add an object for your falling character to hit (trigger) to launch your next scene. Then implement in reverse in the next scene, where the trigger loads the first scene again. You will also see the trigger check box in the inspector panel. Hope this helps. Cheers Chris

I should have also included load level at, http://unity3d.com/support/documentation/ScriptReference/Application.LoadLevel.html

Chris

Hi Damien, sorry for the delayed reply, have been away from my machine. See where you are saying (other:Collider), “other” is the name you are giving to the object. Then you are asking it, is an object you have called player colliding with it, so that is causing your error becasue unity doesn’t know what the player object is. Try changing (player.CompareTag…etc to (other.CcompareTag…etc. Make sure that you have set your game object that is being collided with i.e your cube (and it is also the one you put this script on) is ticked as “is trigger” in the inspector.

Use this:

  function OnTriggerEnter (other: Collider){
        if (other.CompareTag ("Player"))
        Application.LoadLevel ("Painting2");
    }

Cheers Chris