There is a code. He is not mine and he did not write it. It seems, by what I know, it is correct and there are no errors in it. But Unity3D gives an error:
(1, 15) BCE0044 unexpected char ";".
Who will help to make out a problem? I already corrected the given code a little, but all the same does not work.
#pragma strict @script ExecuteInEditMode; function Start () { } var bool : boolean = false; var ts1 : Transform[]; function Update () { if(bool){ bool : false; var ts : new Array(); for(var trans : Transform in transform){ if(!trans.active){ ts.Add(trans); } } ts1 = new Array(ts.Count); for(var i=0; i<ts.length; i++){ ts1[i] = ts[i]; } } }