示例#1
0
 void Awake()
 {
     instance   = this;
     runeslvl   = transform.Find("Lvl").GetComponent <UILabel>();
     border     = transform.Find("Border").GetComponent <UISprite>();
     icon       = transform.Find("Icon").GetComponent <UISprite>();
     count      = transform.Find("CountL").GetComponent <UILabel>();
     powerL     = transform.Find("PowerL").GetComponent <UILabel>();
     addPowerL  = transform.Find("AddPowerL").GetComponent <UILabel>();
     hitL       = transform.Find("HitL").GetComponent <UILabel>();
     addHitL    = transform.Find("AddHitL").GetComponent <UILabel>();
     maskBtn    = transform.Find("MaskBtn").GetComponent <UIButton>();
     wearBtn    = transform.Find("WearBtn").GetComponent <UIButton>();
     detailsTab = transform.Find("DetailsTab").GetComponent <GUISingleCheckBoxGroup>();
     gold       = transform.Find("Gold").GetComponent <UILabel>();
 }
示例#2
0
    protected override void Init()
    {
        base.Init();
        instance              = this;
        HeroPosEmb            = GameObject.Find("HeroPosEmbattle");
        checkBoxs             = transform.Find("CheckBoxs").GetComponent <GUISingleCheckBoxGroup>();
        titleMultList         = transform.Find("ScrollView/MultList").GetComponent <GUISingleMultList>();
        backBtn               = transform.Find("BackBtn").GetComponent <GUISingleButton>();
        titleScrollView       = transform.Find("ScrollView").GetComponent <UIScrollView>();
        promptLabel           = transform.Find("PromptLabel").GetComponent <UILabel>();
        playerTitleName       = transform.Find("PlayerTitleName").GetComponent <UILabel>();
        tweenA                = promptLabel.transform.GetComponent <TweenAlpha>();
        tweenP                = promptLabel.transform.GetComponent <TweenPosition>();
        titleAttributeT       = transform.Find("TitileAttribute");
        grid                  = transform.Find("TitileAttribute/Grid").GetComponent <UIGrid>();
        powerLabel            = transform.Find("TitileAttribute/Grid/powerLabel").GetComponent <UILabel>();
        intelligenceLabel     = transform.Find("TitileAttribute/Grid/intelligenceLabel").GetComponent <UILabel>();
        agilityLabel          = transform.Find("TitileAttribute/Grid/agilityLabel").GetComponent <UILabel>();
        hpLabel               = transform.Find("TitileAttribute/Grid/hpLabel").GetComponent <UILabel>();
        attackLabel           = transform.Find("TitileAttribute/Grid/attackLabel").GetComponent <UILabel>();
        armorLabel            = transform.Find("TitileAttribute/Grid/armorLabel").GetComponent <UILabel>();
        magic_resistLabel     = transform.Find("TitileAttribute/Grid/magic_resistLabel").GetComponent <UILabel>();
        criticalLabel         = transform.Find("TitileAttribute/Grid/criticalLabel").GetComponent <UILabel>();
        dodgeLabel            = transform.Find("TitileAttribute/Grid/dodgeLabel").GetComponent <UILabel>();
        hitratioLabel         = transform.Find("TitileAttribute/Grid/hitratioLabel").GetComponent <UILabel>();
        armorpenetrationLabel = transform.Find("TitileAttribute/Grid/armorpenetrationLabel").GetComponent <UILabel>();
        magicpenetrationLabel = transform.Find("TitileAttribute/Grid/magicpenetrationLabel").GetComponent <UILabel>();
        suckbloodLabel        = transform.Find("TitileAttribute/Grid/suckbloodLabel").GetComponent <UILabel>();
        tenacityLabel         = transform.Find("TitileAttribute/Grid/tenacityLabel").GetComponent <UILabel>();
        mspeed                = transform.Find("TitileAttribute/Grid/mspeed").GetComponent <UILabel>();
        aspeed                = transform.Find("TitileAttribute/Grid/aspeed").GetComponent <UILabel>();
        fanwei                = transform.Find("TitileAttribute/Grid/fanwei").GetComponent <UILabel>();
        nottitleDes           = transform.Find("NotTitleDes");
        backBtn.onClick       = OnBackClick;
        checkBoxs.onClick     = OnTitleClick;

        //InitTitleData();
        //checkBoxs.DefauleIndex = 0;
        //OnTitleClick(0, true);
    }
示例#3
0
    protected override void Init()
    {
        base.Init();
        backBtn           = transform.Find("BackBtn").GetComponent <GUISingleButton>();
        sendBtn           = transform.Find("Button").GetComponent <GUISingleButton>();
        checkBoxs         = transform.Find("CheckBoxs").GetComponent <GUISingleCheckBoxGroup>();
        chatMultList      = transform.Find("ChatScrollView/ChatMultList").GetComponent <GUISingleMultList>();
        chatScrollView    = transform.Find("ChatScrollView").GetComponent <UIScrollView>();
        scrollBar         = transform.Find("ScrollBar").GetComponent <UIScrollBar>();
        inputContent      = transform.Find("Input").GetComponent <UIInput>();
        cannotSpeakObj    = transform.Find("CannotSpeakPrompt").gameObject;
        cannotSpeakLabel  = transform.Find("CannotSpeakPrompt/Label").GetComponent <UILabel>();
        worldHitObj       = transform.Find("Hit/worldHit").gameObject;
        societyHitObj     = transform.Find("Hit/societyHit").gameObject;
        privateHitObj     = transform.Find("Hit/privateHit").gameObject;
        nearbyHitObj      = transform.Find("Hit/nearbyHit").gameObject;
        troopsHitObj      = transform.Find("Hit/troopsHit").gameObject;
        systemHitObj      = transform.Find("Hit/systemHit").gameObject;
        maskObj           = transform.Find("Mask").gameObject;
        horbCoutLabel     = transform.Find("HorbCount").GetComponent <UILabel>();
        horbSprite        = transform.Find("HorbSprite").GetComponent <UISprite>();
        backBtn.onClick   = OnBackBtnClick;
        checkBoxs.onClick = OnChatChannelClick;
        sendBtn.onClick   = OnSendChatClick;
        UIEventListener.Get(maskObj).onClick += OnCloseClick;
        InitChatInfoList();
        JudgePlayerIsCanSpeak();
        //checkBoxs.DefauleIndex = 0;
        //OnChatChannelClick(0, true);
        UIEventListener.Get(inputContent.gameObject).onClick = OnInputClick;
#if UNITY_EDITOR
#elif UNITY_ANDROID
        EventDelegate.Add(inputContent.onSubmit, OnSunmit);
#endif
        //EventDelegate.Add(inputContent.onChange, OnChange);
    }