disable code when level is rendered

I’v probably told you before that i have to disable a script when my level is loaded but the problem is that i don’t know what functions or lines of codes i have to use to get this to work.
I want to disable a loading script when my “Random_Maze” is finished, my “Loading_Script” is:
private var tileCounter = 0;
var height:int = 12;
var width:int = 12;
var updateString: String = “”;

function UpdateProgress() {
    var progress:float = tileCounter/(height*width*6.0);
    	updateString = progress.ToString("Loading: #0%"); 
    	
}
 
function OnGUI(){
	GUI.Box (Rect (0, 0, 3000, 3000),updateString);
		GUI.Box (Rect (0, 0, 3000, 3000),updateString);
			GUI.Box (Rect (0, 0, 3000, 3000),updateString);
				GUI.Box (Rect (0, 0, 3000, 3000),updateString);
					GUI.Box (Rect (0, 0, 3000, 3000),updateString);
						GUI.Box (Rect (0, 0, 3000, 3000),updateString);
							GUI.Box (Rect (0, 0, 3000, 3000),updateString);
								GUI.Box (Rect (0, 0, 3000, 3000),updateString);
									GUI.Box (Rect (0, 0, 3000, 3000),updateString);
										GUI.Box (Rect (Screen.width /2 - 100 ,Screen.height /2 - 0,200,50),updateString );
										
}

can i put like

if (progress.ToString("Loading: 100%")){
script.Loading_Script.isDone
}

or something like that?

You could do a string comparison like

if( updateString  == "Loading: 100%" ) ...

But it seems clumsy. You should test on the actual variable progress like so

if( progress == 100 ) ...

As for disabling a script, you can use enabled = false;