Пример #1
0
    // Use this for initialization
    private void Start()
    {
        this.transform.gameObject.AddComponent(typeof(DiaLog));
        system_log = this.transform.gameObject.GetComponent<DiaLog>();

        this.transform.gameObject.AddComponent(typeof(Inventory));
        system_inventory = this.transform.gameObject.GetComponent<Inventory>();

        this.transform.gameObject.AddComponent(typeof(Solution));
        system_solution = this.transform.gameObject.GetComponent<Solution>();
    }
Пример #2
0
 // Use this for initialization
 private void Start()
 {
     if(singleton == null)
     {
         singleton = this;
     }
 }