hi
i’m using unity 3.5
i want active an object in script
how can i do this?
i use SetActive method but it’s got error
error text :

Assets/Scripts/GameManager.cs(39,34): error CS1061: Type UnityEngine.GameObject' does not contain a definition for SetActive’ and no extension method SetActive' of type UnityEngine.GameObject’ could be found (are you missing a using directive or an assembly reference?)

tnx 4 adv

SetActive reference

GameObject.SetActive() needs to have a lowercase G at the start or replace GameObject with a reference to a game object for example:

var explosion : GameObject;

function Awake ()
{
explosion.SetActive(false);
}

OR

// Deactivates the game object.
            	gameObject.SetActive (false);

GameObject.SetActive() was introduced in Unity 4. In Unity 3.5 it was GameObject.active and GameObject.SetActiveRecursively().

Sources:
http://docs.unity3d.com/Documentation/Manual/UpgradeGuide3540.html
http://answers.unity3d.com/questions/324130/unity4-active-replacement.html
http://answers.unity3d.com/questions/329394/unity-4-gameobjectactive-equivalent.html