void Awake ()
	{
//		instance = this;
		bM = this.gameObject.GetComponentInChildren<BrickManager> ();
		pC = this.gameObject.GetComponentInChildren<PlayerController_old> ();
		pC.gameObject.SetActive (false);

		m_BlockMgr=this.gameObject.GetComponentInChildren<BlockManager> ();

		PlayGameInstance_old.INSTANCE=new PlayGameInstance_old(this);
	}
Example #2
0
    void Awake()
    {
//		instance = this;
        bM = this.gameObject.GetComponentInChildren <BrickManager> ();
        pC = this.gameObject.GetComponentInChildren <PlayerController_old> ();
        pC.gameObject.SetActive(false);

        m_BlockMgr = this.gameObject.GetComponentInChildren <BlockManager> ();

        PlayGameInstance_old.INSTANCE = new PlayGameInstance_old(this);
    }
Example #3
0
    void Start()
    {
        if (levelHelpers == null) {
            levelHelpers = GameObject.Find ("Level Helpers");
        }

        if (leftBorder == null) {
            leftBorder = levelHelpers.transform.Find ("Left Border").gameObject;
        }
        if (rightBorder == null) {
            rightBorder = levelHelpers.transform.Find ("Right Border").gameObject;
        }
        if (spawnZone == null) {
            spawnZone = levelHelpers.transform.Find ("Spawn Zone").gameObject;
        }
        if (levelGenerator == null) {
            levelGenerator = GetComponent<LevelGenerator> ();
        }
        if (statistics == null) {
            statistics = GetComponent<Statistics> ();
        }
        if (playerController == null) {
            playerController = GameObject.Find ("Player Container").GetComponent<PlayerController_old> ();
        }
        if (guiManager == null) {
            guiManager = GameObject.Find ("GUI").GetComponent<GUIManager_old> ();
        }
        if (equipmentCellMap == null) {
            equipmentCellMap = guiManager.transform.Find ("GUI Camera").transform.Find ("Equipment").GetComponent<EquipmentCellMap> ();
        }
    }