void Start()
 {
     if (gm == null)
     {
         gm = GameObject.FindGameObjectWithTag("GM").GetComponent <_GM>();
     }
     anim = elevator_0.GetComponent <Animator>();
     anim.SetBool("NotInUse", true);
 }
Beispiel #2
0
 void Awake()
 {
     instance = this;
     /*if (backMusic != null)
     {
         transform.GetComponent<AudioSource>().clip = backMusic;
         transform.GetComponent<AudioSource>().volume = 0.7f;
     }*/
 }
Beispiel #3
0
    void Awake()
    {
        if (instance == null)
        {
            instance = this;
        }
        else if (instance == this)
        {
            Destroy(gameObject);
        }

        //if (isServer)
        //{
        //READING IN DATASETS - PRIMARILY LIST OF RANDOM NAMES
        int i = 0;
        //StreamReader inp_stm = new StreamReader(Application.dataPath + "/" + "Resources/240_animalNamesList");
        StreamReader inp_stm = new StreamReader(Application.streamingAssetsPath + "//" + "240_animalNamesList");

        while (!inp_stm.EndOfStream)
        {
            string inp_ln = inp_stm.ReadLine();
            animalNames[i] = inp_ln;
            i++;
        }
        inp_stm.Close();
        animalSize = animalNames.Count;
        animalHalf = animalSize / 2;
        i          = 0;

        //inp_stm = new StreamReader(Application.dataPath + "/" + "Resources/240_adjectiveNames");
        inp_stm = new StreamReader(Application.streamingAssetsPath + "//" + "240_adjectiveNames");

        while (!inp_stm.EndOfStream)
        {
            string inp_ln = inp_stm.ReadLine();
            inp_ln = inp_ln.Replace(" ", string.Empty);
            // LastName = LastName.Replace(" ", String.Empty);
            animalAdjectives[i] = inp_ln;
            i++;
        }
        inp_stm.Close();
        adjectiveSize = animalAdjectives.Count;
        adjectiveHalf = adjectiveSize / 2;
        //}

        /*if (!isServer)
         * {
         *  for (int i = 0; i < Clouds.Length; ++i)
         *  {
         *      //print(Clouds[i].transform.GetChild(2));
         *      int r = Random.Range(0, 6);
         *      Clouds[i].transform.GetChild(2).GetComponent<MeshRenderer>().material = matColors[r];
         *      string name = RandomNameGenerator();
         *      Clouds[i].transform.GetChild(3).GetComponent<TextMeshPro>().SetText(name);
         *  }
         * }*/
    }
Beispiel #4
0
    void Awake()
    {
        instance = this;

        /*if (backMusic != null)
         * {
         *  transform.GetComponent<AudioSource>().clip = backMusic;
         *  transform.GetComponent<AudioSource>().volume = 0.7f;
         * }*/
    }
Beispiel #5
0
 // Start is called before the first frame update
 void Start()
 {
     instance = this;
 }
Beispiel #6
0
 // Start is called before the first frame update
 void Start()
 {
     gameManager = GameObject.Find("GameManager").GetComponent <_GM>();
 }
Beispiel #7
0
 private void Start()
 {
     hamburgerMenu.SetActive(false);
     gameManager = FindObjectOfType <_GM>();
 }
 void Start()
 {
     arOrigin    = FindObjectOfType <ARSessionOrigin>();
     gameManager = FindObjectOfType <_GM>();
 }
Beispiel #9
0
 // Start is called before the first frame update
 void Start()
 {
     auswahlPanel.SetActive(false);
     confirmPanel.SetActive(false);
     gameManager = FindObjectOfType <_GM>();
 }