Esempio n. 1
0
    // public method
    // link element component
    public void LinkComponentElement()
    {
        // link structure
        manager = GameObject.FindWithTag("GameLogic").GetComponent <GameManager>();

        // link element component
        storeUI      = transform.Find("StoreUI").gameObject;
        storeUILogic = storeUI.GetComponent <StoreUI>();
        storeUILogic.LinkComponentElement();

        storageUI      = transform.Find("StorageUI").gameObject;
        storageUILogic = storageUI.GetComponent <StorageUI>();

        storeCustomizingSet      = transform.Find("CustomizeUI").gameObject;
        storeCustomizingSetLogic = storeCustomizingSet.GetComponent <CustomizeUI>();
        storeCustomizingSetLogic.LinkComponentElement();

        createUI      = transform.Find("CreateUI").gameObject;
        createUILogic = createUI.GetComponent <CreateUI>();

        sellItemSettingUI      = transform.Find("SellItemSettingUI").gameObject;
        sellItemSettingUILogic = sellItemSettingUI.GetComponent <SellItemSettingUI>();

        furnitureMarketUI      = transform.Find("FurnitureMarketUI").gameObject;
        furnitureMarketUILogic = furnitureMarketUI.GetComponent <FurnitureMarketUI>();

        stageUI      = transform.Find("StageUI").gameObject;
        stageUILogic = stageUI.GetComponent <StageUI>();

        resultRewardUI      = transform.Find("ResultRewardUI").gameObject;
        resultRewardUILogic = resultRewardUI.GetComponent <ResultRewardUI>();

        resultUI      = transform.Find("ResultUI").gameObject;
        resultUILogic = resultUI.GetComponent <ResultUI>();

        chatSceneUI      = transform.Find("ChatScene").gameObject;
        chatSceneUILogic = chatSceneUI.GetComponent <ChatSceneUI>();

        characterCreateUI      = transform.Find("CharacterCreateUI").gameObject;
        characterCreateUILogic = characterCreateUI.GetComponent <CharacterCreateUI>();

        questUI      = transform.Find("QuestUI").gameObject;
        questUILogic = questUI.GetComponent <QuestUI>();
        questUILogic.LinkComponentElement();

        loadingScene = transform.Find("LoadingScene").gameObject;
    }