Exemplo n.º 1
0
    void Awake()
    {
        optionListUI  = OptionListUI.GetInstance();
        rectTransform = GetComponent <RectTransform>();
        cardCubeList  = new List <GameObject>();
        if (!isCover)
        {
            cardCubeDic = new Dictionary <GameObject, string>();
        }

        deckNumText  = transform.FindChild("Text").GetComponent <Text>();
        rawImage     = GetComponent <RawImage>();
        coverTexture = Resources.Load("Prefebs/cover") as Texture;
        if (isMine)
        {
            cardCube = Resources.Load("Prefebs/cardCube") as GameObject;
        }
        else
        {
            cardCube = Resources.Load("Prefebs/cardCube_Small") as GameObject;
        }
        cardNum = 0;
        Transform theAct = transform.FindChild("ActImage");

        if (theAct != null)
        {
            actImage = theAct.GetComponent <ActImage>();
            actImage.gameObject.SetActive(false);
        }

        UpdateText();
    }
Exemplo n.º 2
0
    void Awake()
    {
        //gameFieldUI = GameFieldUI.GetInstance();
        rectTransform = this.GetComponent <RectTransform>();
        coverTexture  = Resources.Load("Prefebs/cover") as Texture;


        optionListUI = OptionListUI.GetInstance();
    }
Exemplo n.º 3
0
    void Awake()
    {
        duel    = Duel.GetInstance();
        mDeckUI = transform.FindChild("MDeckUI").GetComponent <GameFieldUI>();
        oDeckUI = transform.FindChild("ODeckUI").GetComponent <GameFieldUI>();

        mHandCardUI = transform.FindChild("MHandCard").GetComponent <HandCardUI>();
        oHandCardUI = transform.FindChild("OHandCard").GetComponent <HandCardUI>();
        mHandCardUI.Init();
        oHandCardUI.Init();

        mFieldMgr = transform.FindChild("MField").GetComponent <FieldMgr>();
        oFieldMgr = transform.FindChild("OField").GetComponent <FieldMgr>();
        mFieldMgr.Init(true);
        oFieldMgr.Init(false);

        mLpSliderUI = transform.FindChild("LPSlider_player1").GetComponent <LPSliderUI>();
        oLpSliderUI = transform.FindChild("LPSlider_player2").GetComponent <LPSliderUI>();

        lpChangeUI       = transform.FindChild("lpChangeUI").GetComponent <LPChangeUI>();
        cardEffectAnim   = transform.FindChild("CardEffectAnim").GetComponent <CardEffectAnim>();
        selectEffectUI   = transform.FindChild("SelectEffectUI").GetComponent <SelectEffectUI>();
        phaseButtonMgr   = transform.FindChild("PhaseButton").GetComponent <PhaseButtonMgr>();
        guessFirst       = transform.FindChild("GuessFirst").GetComponent <GuessFirst>();
        floatText        = transform.FindChild("FloatText").GetComponent <FloatText>();
        selectCardShowUI = transform.FindChild("SelectCardShow").GetComponent <SelectCardShowUI>();
        selectPutType    = transform.FindChild("SelectPutType").GetComponent <SelectPutType>();
        mDrawCardAnim    = transform.FindChild("MDrawCardAnim").GetComponent <DrawCardAnim>();
        oDrawCardAnim    = transform.FindChild("ODrawCardAnim").GetComponent <DrawCardAnim>();
        attackAnim       = transform.FindChild("AttackAnim").GetComponent <AttactAnim>();
        roundCounterUI   = GetChild <RoundCountUI>("RoundNumText");

        mChangeAreaAnim = GetChild <ChangeAreaAnim>("MAnim");
        oChangeAreaAnim = GetChild <ChangeAreaAnim>("OAnim");

        chainUICtr = GetChild <ChainUICtr>("ChainUIMgr");

        selectCardMgr = SelectCardMgr.GetInstance();
        optionListUI  = OptionListUI.GetInstance();
        dialogBoxUI   = DialogBoxUI.GetInstance();
        selectCardUI  = SelectCardUI.GetInstance();
        tipPlane      = ErrorPlane.GetInstance();

        selectCardMgr.Init();
        phaseButtonMgr.Init();
        selectEffectUI.Init();
        cardEffectAnim.Init();
        lpChangeUI.Init();
        optionListUI.Init();
        dialogBoxUI.Init();
        selectCardUI.Init();
        selectPutType.Init();
        attackAnim.Init();
    }
Exemplo n.º 4
0
 public void Init()
 {
     optionListUI = OptionListUI.GetInstance();
     text         = this.transform.FindChild("Text").GetComponent <Text>();
 }
Exemplo n.º 5
0
 public OptionListUI()
 {
     instance = this;
 }