Esempio n. 1
0
 void Awake()
 {
     instance = this;
     if (objectsContainer == null)
     {
         objectsContainer = this.gameObject.GetComponent <Transform>();
     }
     if (cameraPivot == null)
     {
         cameraPivot = this.gameObject.GetComponentInChildren <CopyGlobalPosition>();
     }
     gameObjectNames = new List <string>();
     gameObjects     = new Dictionary <string, GameObject>();
     cameraTargets   = new Dictionary <string, Transform>();
     if (delayedRegistrations != null)
     {
         foreach (ProgrammableObject programmableObject in delayedRegistrations)
         {
             instance.RegisterProgrammableObject(programmableObject);
         }
     }
     //this.gameObject.SetActive(false);
 }
Esempio n. 2
0
 void Awake()
 {
     instance = this;
     if (objectsContainer == null)
         objectsContainer = this.gameObject.GetComponent<Transform>();
     if (cameraPivot == null)
         cameraPivot = this.gameObject.GetComponentInChildren<CopyGlobalPosition>();
     gameObjectNames = new List<string>();
     gameObjects = new Dictionary<string,GameObject>();
     cameraTargets = new Dictionary<string,Transform>();
     if (delayedRegistrations != null)
     {
         foreach (ProgrammableObject programmableObject in delayedRegistrations)
             instance.RegisterProgrammableObject(programmableObject);
     }
     //this.gameObject.SetActive(false);
 }