not working script?

so im using this script…

var timeLimit : float = 60; // 1 minute timer
var nextMap : String = "zone2"; // Change this to next level for each scene.
 
Invoke("NextMap", timeLimit);
 
function NextMap() {
    Application.LoadLevel(nextMap);
}

and it is flat out not working.
its on javascript, the scenes are loaded into the builder, why isnt it working?

We're going to need to now how it isn't working. Are you getting an error? Is it running but just not switching levels? Try debugging to the log in NextMap() so you know the function is being executed.

do yourself

1 Answer

1

I just tried the code, It worked fine.

I have had other problems similar to this after downloading from the asset store. It could be that.

Try create a new project and test the code.

I just figured out what was wrong, the timescale in the project is bugged out, all time seems to stand still. thanks for trying it