Beispiel #1
0
        public override void Awake()
        {
            base.Awake();

            var t = controller.transform;

            PlaceholderWidget   = t.GetComponent <UIWidget>("Content/Reward/Placeholder");
            ScrollVew           = t.GetComponent <UIScrollView>("Content/Reward");
            m_UIDynamicShowItem = t.GetMonoILRComponent <UIDynamicShowItem>("Content/Reward/Placeholder/RewardGrid");
            m_UIDynamicShowItem.OnShowFinished = TweenFinishCallBack;
            ClickTips = t.FindEx("Content/Tip").gameObject;
            BlurBG    = t.FindEx("Bg").gameObject;
            BlurBG.CustomSetActive(true);
            fx                = t.FindEx("Bg/FX").gameObject;
            ClickBtn          = t.FindEx("Content/ClickBtns").gameObject;
            titleObj          = t.FindEx("Content/Title").gameObject;
            NegativeLabel     = t.GetComponent <UILabel>("Content/ClickBtns/NegativeBtn/Label");
            PositiveLabel     = t.GetComponent <UILabel>("Content/ClickBtns/PositiveBtn/Label");
            PositiveCostLabel = t.GetComponent <UILabel>("Content/ClickBtns/PositiveBtn/CoinLabel");
            PositiveSprite    = t.GetComponent <DynamicUISprite>("Content/ClickBtns/PositiveBtn/CoinLabel/Sprite");

            t.GetComponent <UIEventTrigger>("Bg").onClick.Add(new EventDelegate(OnCancelButtonClick));
            t.GetComponent <ConsecutiveClickCoolTrigger>("Content/ClickBtns/NegativeBtn").clickEvent.Add(new EventDelegate(OnNegativeBtnClick));
            t.GetComponent <ConsecutiveClickCoolTrigger>("Content/ClickBtns/PositiveBtn").clickEvent.Add(new EventDelegate(OnPositiveBtnClick));

            mNextItemDataQueue = new Queue <List <LTShowItemData> >();
        }
Beispiel #2
0
        public override void Awake()
        {
            base.Awake();

            var t = controller.transform;

            m_UIDynamicShowItem = t.GetMonoILRComponent <UIDynamicShowItem>("ShowReward/RewardGrid");
            FxObj    = t.FindEx("FxObj").gameObject;
            TitleObj = t.FindEx("Title").gameObject;
        }