Exemplo n.º 1
0
 // Use this for initialization
 void Start()
 {
     _BBE    = FindObjectOfType <BigBirdEmitter>().GetComponent <BigBirdEmitter>();
     _player = FindObjectOfType <PlayerController>().GetComponent <Transform>();
     _box    = gameObject.GetComponent <BoxCollider>();
     _ME     = FindObjectOfType <MusicEmitter>().GetComponent <MusicEmitter>();
 }
Exemplo n.º 2
0
 void Awake()
 {
     if (instance == null)
     {
         instance = this;
     }
     else if (instance != this)
     {
         Destroy(gameObject);
     }
 }