コード例 #1
0
ファイル: UITitle.cs プロジェクト: vm-t-yui/vmlib-sample
    /// <summary>
    /// 初期化.
    /// </summary>
    public override void Start()
    {
        GameServiceUtil.Auth();
#if USE_TWEEN
        tweenAlphe = GetComponent <uTweenAlpha>();
#endif
    }
コード例 #2
0
ファイル: WorldMap.cs プロジェクト: MrZivChu/ciyuanfangyu
    void ClickMap(GameObject obj, object param)
    {
        if (obj != preMap)
        {
            if (preMap != null)
            {
                Transform ticon = preMap.transform.parent.GetChild(0);
                ticon.GetComponent <uTweenAlpha>().enabled = false;
                ticon.GetComponent <Image>().color         = Color.white;

                Transform tdata = preMap.transform.parent.GetChild(2);
                tdata.localScale = Vector3.zero;
                tdata.gameObject.SetActive(false);
                Vector3 pos = Vector3.zero;
                pos.x = 160;
                tdata.GetComponent <RectTransform>().anchoredPosition = pos;
            }

            Transform icon = obj.transform.parent.GetChild(0);
            icon.GetComponent <uTweenAlpha>().enabled = true;
            Transform data = obj.transform.parent.GetChild(2);
            data.localScale = Vector3.one;
            data.gameObject.SetActive(true);
            uTweenAlpha    tuTweenAlpha    = data.GetComponent <uTweenAlpha>();
            uTweenPosition tuTweenPosition = data.GetComponent <uTweenPosition>();
            tuTweenAlpha.Reset();
            tuTweenPosition.Reset();
            preMap = obj;
        }
    }
コード例 #3
0
ファイル: DodgeGauge.cs プロジェクト: Pacman18/ProudTest
    void Awake()
    {
        var gauge = GetComponentsInChildren <UIFillGauge>();

        _enemyGauge = gauge[0];
        _myGauge    = gauge[1];

        _title      = GetText(GlobalUtil.TextTitle);
        _tweenAlpha = GetComponent <uTweenAlpha>();
        _tweenPos   = GetComponent <uTweenPosition>();
    }
コード例 #4
0
    void Awake()
    {
        _message = GetComponentInChildren <Text>();
        _alpha   = GetComponentInChildren <uTweenAlpha>(true);

        UnityEvent endEvent2 = new UnityEvent();

        endEvent2.AddListener(() =>
        {
            UIManager.i.RemoveGameUI(this);
        });
        _alpha.SetOnFinished(endEvent2);
    }
コード例 #5
0
ファイル: UIAlliance_Marshal.cs プロジェクト: gsoec/lm-source
    // Token: 0x06000F54 RID: 3924 RVA: 0x001B1A78 File Offset: 0x001AFC78
    public void Init()
    {
        GUIManager  instance    = GUIManager.Instance;
        uTweenScale uTweenScale = this.GuideObject.transform.GetChild(0).gameObject.AddComponent <uTweenScale>();

        uTweenScale.easeType  = EaseType.linear;
        uTweenScale.loopStyle = LoopStyle.Loop;
        uTweenScale.delay     = 0.2f;
        uTweenScale.from      = Vector3.one;
        uTweenScale.to        = new Vector3(3f, 3f, 3f);
        uTweenAlpha uTweenAlpha = this.GuideObject.transform.GetChild(0).gameObject.AddComponent <uTweenAlpha>();

        uTweenAlpha.easeType         = EaseType.linear;
        uTweenAlpha.loopStyle        = LoopStyle.Loop;
        uTweenAlpha.delay            = 0.2f;
        uTweenAlpha.from             = 1f;
        uTweenAlpha.to               = 0f;
        uTweenAlpha.mMaskableGraphic = this.GuideObject.transform.GetChild(0).GetComponent <Image>();
        uTweenPosition uTweenPosition = this.GuideObject.transform.GetChild(1).gameObject.AddComponent <uTweenPosition>();

        uTweenPosition.easeType  = EaseType.easeOutQuad;
        uTweenPosition.loopStyle = LoopStyle.PingPong;
        uTweenPosition.duration  = 0.5f;
        uTweenPosition.from      = new Vector3(224f, 17.8f, 0f);
        uTweenPosition.to        = new Vector3(241f, 0.8f, 0f);
        Transform child = this.ThisTransform.GetChild(5);

        instance.InitianHeroItemImg(child.GetChild(0).GetChild(1).GetChild(0), eHeroOrItem.Hero, 0, 0, 0, 0, false, false, false, false);
        instance.InitianHeroItemImg(child.GetChild(1).GetChild(1).GetChild(0), eHeroOrItem.Hero, 0, 0, 0, 0, false, false, false, false);
        this.ItemCount     = 5;
        this.ItemEdit      = new UIAlliance_Marshal.MarshalList[(int)this.ItemCount];
        this.WarScrollView = this.ThisTransform.GetChild(4).GetChild(0).GetComponent <ScrollPanel>();
        byte b = 0;

        while ((ushort)b < this.ItemCount)
        {
            this.ItemsHeight.Add(128f);
            b += 1;
        }
        this.WarScrollView.IntiScrollPanel(435f, 0f, 3f, this.ItemsHeight, (int)this.ItemCount, this);
        this.Content = this.ThisTransform.GetChild(4).GetChild(0).GetChild(0).GetComponent <RectTransform>();
        DataManager.Instance.CheckWalHall_List();
        if (instance.MarshalSaved == 0)
        {
            this.ChangeTag(this.CurrentTag, true);
        }
        else
        {
            this.ChangeTag((UIAlliance_Marshal.ClickType)(instance.MarshalSaved - 1), true);
        }
    }
コード例 #6
0
        void Scale(bool scale)
        {
            if (scale)
            {
                inLight.SetActive(true);
                uTweenAlpha tw1 = uTweenAlpha.Begin <uTweenAlpha>(inLight, inDuration);
                tw1.from     = 1f;
                tw1.to       = 0f;
                tw1.duration = inDuration;

                outLight.SetActive(true);
                uTweenAlpha tw2 = uTweenAlpha.Begin <uTweenAlpha>(outLight, outDuration);
                tw2.from     = 1f;
                tw2.to       = 0f;
                tw2.duration = outDuration;
                tw2.delay    = outDelay;

                uTweenScale tw3 = uTweenScale.Begin(outLight, from, to, outDuration, outDelay);
            }
        }
コード例 #7
0
ファイル: PowerChargeUI.cs プロジェクト: Pacman18/ProudTest
 void Awake()
 {
     _tween   = GetComponentInChildren <uTweenAlpha>();
     _slider  = GetComponentInChildren <UISlideGauge>();
     _backImg = GetImage(MaxImage);
 }
コード例 #8
0
        //void Awake()
        //{
        //    canvasGroup = this.GetComponent<CanvasGroup>();
        //}

        void OnEnable()
        {
            tween       = uTweenAlpha.Begin(this.gameObject, lowAlpha, highAlpha, time, 0, includeChildren);
            tween.style = uTweener.Style.PingPong;
        }
コード例 #9
0
ファイル: BlackWindow.cs プロジェクト: Pacman18/ProudTest
 void Awake()
 {
     _tween = GetComponentInChildren <uTweenAlpha>(true);
 }